mirror of
https://github.com/pgsty/minio.git
synced 2026-07-22 05:30:24 +03:00
Add env variables to configuration APIs output (#15465)
Config export and config get APIs now include environment variables set on the server
This commit is contained in:
committed by
GitHub
parent
f4af2d3cdc
commit
3d94c38ec4
+1
-2
@@ -508,8 +508,7 @@ func parsEnvEntry(envEntry string) (envKV, error) {
|
||||
Skip: true,
|
||||
}, nil
|
||||
}
|
||||
const envSeparator = "="
|
||||
envTokens := strings.SplitN(strings.TrimSpace(strings.TrimPrefix(envEntry, "export")), envSeparator, 2)
|
||||
envTokens := strings.SplitN(strings.TrimSpace(strings.TrimPrefix(envEntry, "export")), config.EnvSeparator, 2)
|
||||
if len(envTokens) != 2 {
|
||||
return envKV{}, fmt.Errorf("envEntry malformed; %s, expected to be of form 'KEY=value'", envEntry)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user