Skip to content
This repository was archived by the owner on Jul 19, 2023. It is now read-only.

Commit afd84cc

Browse files
authored
Add missing flags to expand config file (#492)
1 parent 36452e1 commit afd84cc

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

pkg/phlare/phlare.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,9 @@ type Config struct {
6262
MultitenancyEnabled bool `yaml:"multitenancy_enabled,omitempty"`
6363
Analytics usagestats.Config `yaml:"analytics"`
6464

65-
ConfigFile string `yaml:"-"`
66-
ShowVersion bool `yaml:"-"`
65+
ConfigFile string `yaml:"-"`
66+
ShowVersion bool `yaml:"-"`
67+
ConfigExpandEnv bool `yaml:"-"`
6768
}
6869

6970
func newDefaultConfig() *Config {
@@ -94,6 +95,7 @@ func (c *Config) RegisterFlagsWithContext(ctx context.Context, f *flag.FlagSet)
9495
"The alias 'all' can be used in the list to load a number of core modules and will enable single-binary mode. ")
9596
f.BoolVar(&c.MultitenancyEnabled, "auth.multitenancy-enabled", false, "When set to true, incoming HTTP requests must specify tenant ID in HTTP X-Scope-OrgId header. When set to false, tenant ID anonymous is used instead.")
9697
f.BoolVar(&c.ShowVersion, "version", false, "Show the version of phlare and exit")
98+
f.BoolVar(&c.ConfigExpandEnv, "config.expand-env", false, "Expands ${var} in config according to the values of the environment variables.")
9799

98100
c.registerServerFlagsWithChangedDefaultValues(f)
99101
c.AgentConfig.RegisterFlags(f)

0 commit comments

Comments
 (0)