config에 env 환경 변수 적용

This commit is contained in:
2024-06-04 10:25:46 +09:00
parent 6608784709
commit f470966d30

View File

@ -65,7 +65,7 @@ func LoadConfig[T any](outptr *T) error {
return os.WriteFile(configfilepath, []byte("{}"), 0666)
}
return json.Unmarshal(content, outptr)
return json.Unmarshal([]byte(os.ExpandEnv(string(content))), outptr)
}
type StorageAddr struct {