configs

package
v0.0.0-...-6a62363 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 28, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cfg

type Cfg struct {
	Server   ServerCfg   `yaml:"server"`
	Database DatabaseCfg `yaml:"database"`
}

Cfg represents the configuration of application.

var AppCfg *Cfg

AppCfg represents the configuration of application.

type DatabaseCfg

type DatabaseCfg struct {
	Dsn      string `yaml:"dsn"`
	LogLevel string `yaml:"logLevel"`
}

DatabaseCfg present the configuration of database.

type ServerCfg

type ServerCfg struct {
	Name         string `yaml:"name"`
	Port         string `yaml:"port"`
	Prefork      bool   `yaml:"prefork"`
	ReadTimeout  uint   `yaml:"readTimeout"`
	WriteTimeout uint   `yaml:"writeTimeout"`
}

ServerCfg present the configuration of server.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL