Documentation
¶
Index ¶
Constants ¶
View Source
const (
CONFIG_FILE_NAME = "gte.config.json"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Host string `json:"host"`
Port int `json:"port"`
Routes []Route `json:"routes"`
NotFoundPage string `json:"notFoundPage"`
BlackList []string `json:"blackList"`
ApiServer string `json:"apiServer"` //API server, e.g. "http://localhost:12300"
Envs map[string]Config `json:"envs"` //customized environments
Lang struct {
Dir string `json:"dir"` //language resources location
Default string `json:"default"` //default language, e.g. 'zh-CN'
KeyAsValue bool `json:"keyAsValue"` //return key as value when request of default language comes
} `json:"lang"` //language setup
Root string `json:"-"` //root directory of your project
Env string `json:"-"`
InternalBlackList []string `json:"-"`
Strs map[string]map[string]string `json:"-"`
}
Click to show internal directories.
Click to hide internal directories.