This commit is contained in:
wjqserver 2025-06-20 16:33:27 +08:00
commit b10790c212
40 changed files with 4149 additions and 0 deletions

40
db/struct.go Normal file
View file

@ -0,0 +1,40 @@
package db
/*
// 通用配置结构
type CaddyfileConfig struct {
Domain string `json:"domain"`
TmplType string `json:"tmpl_type"`
UpStream UpStreamConfig `json:"upstream"`
FileServer FileServerConfig `json:"file_server"`
Headers map[string][]string `json:"headers"`
Log LogConfig `json:"log"`
ErrorPage ErrorPageConfig `json:"error_page"`
Encode EncodeConfig `json:"encode"`
}
type UpStreamConfig struct {
UpStream string `json:"upstream"`
MutiUpStream bool `json:"muti_upstream"`
UpStreams []string `json:"upstream_servers"`
UpStreamHeaders map[string][]string `json:"upstream_headers"`
}
type FileServerConfig struct {
FileDirPath string `json:"file_dir_path"`
EnableBrowser bool `json:"enable_browser"`
}
type LogConfig struct {
EnableLog bool `json:"enable_log"`
LogDomain string `json:"log_domain"`
}
type ErrorPageConfig struct {
EnableErrorPage bool `json:"enable_error_page"`
}
type EncodeConfig struct {
EnableEncode bool `json:"enable_encode"`
}
*/