forked from TrueCloudLab/frostfs-node
[#1] Fix viper env prefix in cli tools
Changing env prefix and corresponding example config files. Signed-off-by: Stanislav Bogatyrev <s.bogatyrev@yadro.com>
This commit is contained in:
parent
73bc1b0b68
commit
1858f11146
12 changed files with 224 additions and 224 deletions
|
@ -8,14 +8,14 @@ import (
|
|||
)
|
||||
|
||||
func newConfig(path string) (*viper.Viper, error) {
|
||||
const innerRingPrefix = "neofs_ir"
|
||||
const envPrefix = "FROSTFS_IR"
|
||||
|
||||
var (
|
||||
err error
|
||||
v = viper.New()
|
||||
)
|
||||
|
||||
v.SetEnvPrefix(innerRingPrefix)
|
||||
v.SetEnvPrefix(envPrefix)
|
||||
v.AutomaticEnv()
|
||||
v.SetEnvKeyReplacer(strings.NewReplacer(".", "_"))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue