Update server configuration to disable serving frontend
This commit is contained in:
parent
5cfb906a4f
commit
a88946bb7f
7 changed files with 57 additions and 42 deletions
|
@ -48,6 +48,7 @@ type ServerConfig struct {
|
|||
ReadTimeout time.Duration `mapstructure:"read_timeout" yaml:"read_timeout"`
|
||||
WriteTimeout time.Duration `mapstructure:"write_timeout" yaml:"write_timeout"`
|
||||
CorsAllowOrigins []string `mapstructure:"cors_allow_origins" yaml:"cors_allow_origins"`
|
||||
ServeFrontend bool `mapstructure:"serve_frontend" yaml:"serve_frontend"`
|
||||
}
|
||||
|
||||
type SchedulerConfig struct {
|
||||
|
@ -105,6 +106,8 @@ func LoadConfig() *Config {
|
|||
viper.SetConfigName("local")
|
||||
} else if os.Getenv("CA_ENV") == "prod" {
|
||||
viper.SetConfigName("prod")
|
||||
} else if os.Getenv("CA_ENV") == "selfhosted" {
|
||||
viper.SetConfigName("selfhosted")
|
||||
} else {
|
||||
viper.SetConfigName("local")
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue