mirror of
https://github.com/yusing/godoxy.git
synced 2026-04-23 16:58:31 +02:00
[BREAKING] added entrypoint middleware support and config, config schema update
This commit is contained in:
@@ -2,19 +2,22 @@ package types
|
||||
|
||||
type (
|
||||
Config struct {
|
||||
Providers Providers `json:"providers" yaml:",flow"`
|
||||
AutoCert AutoCertConfig `json:"autocert" yaml:",flow"`
|
||||
ExplicitOnly bool `json:"explicit_only" yaml:"explicit_only"`
|
||||
Entrypoint Entrypoint `json:"entrypoint" yaml:",flow"`
|
||||
Providers Providers `json:"providers" yaml:",flow"`
|
||||
MatchDomains []string `json:"match_domains" yaml:"match_domains"`
|
||||
Homepage HomepageConfig `json:"homepage" yaml:"homepage"`
|
||||
TimeoutShutdown int `json:"timeout_shutdown" yaml:"timeout_shutdown"`
|
||||
RedirectToHTTPS bool `json:"redirect_to_https" yaml:"redirect_to_https"`
|
||||
}
|
||||
Providers struct {
|
||||
Files []string `json:"include" yaml:"include"`
|
||||
Docker map[string]string `json:"docker" yaml:"docker"`
|
||||
Notification []NotificationConfig `json:"notification" yaml:"notification"`
|
||||
}
|
||||
Entrypoint struct {
|
||||
RedirectToHTTPS bool `json:"redirect_to_https" yaml:"redirect_to_https"`
|
||||
Middlewares []map[string]any
|
||||
}
|
||||
NotificationConfig map[string]any
|
||||
)
|
||||
|
||||
@@ -24,6 +27,8 @@ func DefaultConfig() *Config {
|
||||
Homepage: HomepageConfig{
|
||||
UseDefaultCategories: true,
|
||||
},
|
||||
RedirectToHTTPS: false,
|
||||
Entrypoint: Entrypoint{
|
||||
RedirectToHTTPS: false,
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user