diff --git a/config/config.go b/config/config.go index bc4ddebf..6990cbd6 100644 --- a/config/config.go +++ b/config/config.go @@ -38,8 +38,6 @@ var ( // ErrInvalidSecurityConfig is an error returned when the security configuration is invalid ErrInvalidSecurityConfig = errors.New("invalid security configuration") - - dontExpandEnv = os.Getenv("GATUS_DONT_EXPAND_ENV") == "true" ) // Config is the main configuration structure @@ -154,9 +152,7 @@ func readConfigurationFile(fileName string) (config *Config, err error) { // parseAndValidateConfigBytes parses a Gatus configuration file into a Config struct and validates its parameters func parseAndValidateConfigBytes(yamlBytes []byte) (config *Config, err error) { // Expand environment variables - if !dontExpandEnv { - yamlBytes = []byte(os.ExpandEnv(string(yamlBytes))) - } + yamlBytes = []byte(os.ExpandEnv(string(yamlBytes))) // Parse configuration file if err = yaml.Unmarshal(yamlBytes, &config); err != nil { return