f
This commit is contained in:
@@ -46,6 +46,7 @@ type Config struct {
|
||||
PDFGen PDFGenConfig `mapstructure:"pdfgen"`
|
||||
Huibo HuiboConfig `mapstructure:"huibo"`
|
||||
Nuoer NuoerConfig `mapstructure:"nuoer"`
|
||||
Haiyuapi HaiyuapiConfig `mapstructure:"haiyuapi"`
|
||||
}
|
||||
|
||||
// ServerConfig HTTP服务器配置
|
||||
@@ -734,6 +735,34 @@ type NuoerLevelFileConfig struct {
|
||||
Compress bool `mapstructure:"compress"`
|
||||
}
|
||||
|
||||
// HaiyuapiConfig 海宇API(上游数据源)配置
|
||||
type HaiyuapiConfig struct {
|
||||
BaseURL string `mapstructure:"base_url"`
|
||||
AccessID string `mapstructure:"access_id"`
|
||||
SecretKey string `mapstructure:"secret_key"`
|
||||
Timeout time.Duration `mapstructure:"timeout"`
|
||||
|
||||
Logging HaiyuapiLoggingConfig `mapstructure:"logging"`
|
||||
}
|
||||
|
||||
// HaiyuapiLoggingConfig 海宇API日志配置
|
||||
type HaiyuapiLoggingConfig 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]HaiyuapiLevelFileConfig `mapstructure:"level_configs"`
|
||||
}
|
||||
|
||||
// HaiyuapiLevelFileConfig 海宇API级别文件配置
|
||||
type HaiyuapiLevelFileConfig 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