f
This commit is contained in:
@@ -47,6 +47,7 @@ type Config struct {
|
||||
Huibo HuiboConfig `mapstructure:"huibo"`
|
||||
Nuoer NuoerConfig `mapstructure:"nuoer"`
|
||||
Haiyuapi HaiyuapiConfig `mapstructure:"haiyuapi"`
|
||||
Yuyuecha YuyuechaConfig `mapstructure:"yuyuecha"`
|
||||
QueryWhitelist QueryWhitelistConfig `mapstructure:"query_whitelist"`
|
||||
}
|
||||
|
||||
@@ -775,6 +776,34 @@ type HaiyuapiLevelFileConfig struct {
|
||||
Compress bool `mapstructure:"compress"`
|
||||
}
|
||||
|
||||
// YuyuechaConfig 愉悦查 OpenAPI 配置
|
||||
type YuyuechaConfig struct {
|
||||
BaseURL string `mapstructure:"base_url"`
|
||||
ClientID string `mapstructure:"client_id"`
|
||||
ClientSecret string `mapstructure:"client_secret"`
|
||||
Timeout time.Duration `mapstructure:"timeout"`
|
||||
|
||||
Logging YuyuechaLoggingConfig `mapstructure:"logging"`
|
||||
}
|
||||
|
||||
// YuyuechaLoggingConfig 愉悦查日志配置
|
||||
type YuyuechaLoggingConfig struct {
|
||||
Enabled bool `mapstructure:"enabled"`
|
||||
LogDir string `mapstructure:"log_dir"`
|
||||
ServiceName string `mapstructure:"service_name"`
|
||||
UseDaily bool `mapstructure:"use_daily"`
|
||||
EnableLevelSeparation bool `mapstructure:"enable_level_separation"`
|
||||
LevelConfigs map[string]YuyuechaLevelFileConfig `mapstructure:"level_configs"`
|
||||
}
|
||||
|
||||
// YuyuechaLevelFileConfig 愉悦查级别文件配置
|
||||
type YuyuechaLevelFileConfig struct {
|
||||
MaxSize int `mapstructure:"max_size"`
|
||||
MaxBackups int `mapstructure:"max_backups"`
|
||||
MaxAge int `mapstructure:"max_age"`
|
||||
Compress bool `mapstructure:"compress"`
|
||||
}
|
||||
|
||||
// DomainConfig 域名配置
|
||||
type DomainConfig struct {
|
||||
API string `mapstructure:"api"` // API域名
|
||||
|
||||
Reference in New Issue
Block a user