mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-05-03 17:29:22 -05:00
sort out flags precedence
This commit is contained in:
Vendored
+2
-2
@@ -14,6 +14,6 @@
|
||||
"OCIS_LOG_COLOR": "true",
|
||||
"PROXY_ENABLE_BASIC_AUTH": "true"
|
||||
}
|
||||
},
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,31 +13,31 @@ func StructMappings(cfg *Config) []shared.EnvBinding {
|
||||
func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
return []shared.EnvBinding{
|
||||
{
|
||||
EnvVars: []string{"ACCOUNTS_LOG_FILE", "OCIS_LOG_FILE"},
|
||||
EnvVars: []string{"OCIS_LOG_FILE", "ACCOUNTS_LOG_FILE"},
|
||||
Destination: &cfg.Log.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"ACCOUNTS_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "ACCOUNTS_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"ACCOUNTS_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "ACCOUNTS_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"ACCOUNTS_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "ACCOUNTS_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"ACCOUNTS_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "ACCOUNTS_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"ACCOUNTS_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "ACCOUNTS_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"ACCOUNTS_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "ACCOUNTS_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
@@ -85,7 +85,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.Asset.Path,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"ACCOUNTS_JWT_SECRET", "OCIS_JWT_SECRET"},
|
||||
EnvVars: []string{"OCIS_JWT_SECRET", "ACCOUNTS_JWT_SECRET"},
|
||||
Destination: &cfg.TokenManager.JWTSecret,
|
||||
},
|
||||
{
|
||||
@@ -109,7 +109,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.Repo.CS3.DataPrefix,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"ACCOUNTS_STORAGE_CS3_JWT_SECRET", "OCIS_JWT_SECRET"},
|
||||
EnvVars: []string{"OCIS_JWT_SECRET", "ACCOUNTS_STORAGE_CS3_JWT_SECRET"},
|
||||
Destination: &cfg.Repo.CS3.JWTSecret,
|
||||
},
|
||||
{
|
||||
|
||||
@@ -13,19 +13,19 @@ func StructMappings(cfg *Config) []shared.EnvBinding {
|
||||
func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
return []shared.EnvBinding{
|
||||
{
|
||||
EnvVars: []string{"GLAUTH_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "GLAUTH_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GLAUTH_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "GLAUTH_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GLAUTH_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "GLAUTH_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GLAUTH_LOG_FILE", "OCIS_LOG_FILE"},
|
||||
EnvVars: []string{"OCIS_LOG_FILE", "GLAUTH_LOG_FILE"},
|
||||
Destination: &cfg.Log.File,
|
||||
},
|
||||
{
|
||||
@@ -33,19 +33,19 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GLAUTH_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "GLAUTH_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GLAUTH_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "GLAUTH_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GLAUTH_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "GLAUTH_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GLAUTH_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "GLAUTH_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
|
||||
@@ -13,35 +13,35 @@ func StructMappings(cfg *Config) []shared.EnvBinding {
|
||||
func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
return []shared.EnvBinding{
|
||||
{
|
||||
EnvVars: []string{"GRAPH_EXPLORER_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "GRAPH_EXPLORER_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_EXPLORER_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "GRAPH_EXPLORER_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_EXPLORER_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "GRAPH_EXPLORER_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_EXPLORER_LOG_FILE", "OCIS_LOG_FILE"},
|
||||
EnvVars: []string{"OCIS_LOG_FILE", "GRAPH_EXPLORER_LOG_FILE"},
|
||||
Destination: &cfg.Log.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_EXPLORER_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "GRAPH_EXPLORER_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_EXPLORER_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "GRAPH_EXPLORER_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_EXPLORER_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "GRAPH_EXPLORER_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_EXPLORER_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "GRAPH_EXPLORER_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
@@ -77,7 +77,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.HTTP.Namespace,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_EXPLORER_ISSUER", "OCIS_URL"},
|
||||
EnvVars: []string{"OCIS_URL", "GRAPH_EXPLORER_ISSUER"},
|
||||
Destination: &cfg.GraphExplorer.Issuer,
|
||||
},
|
||||
{
|
||||
@@ -85,7 +85,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.GraphExplorer.ClientID,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_EXPLORER_GRAPH_URL_BASE", "OCIS_URL"},
|
||||
EnvVars: []string{"OCIS_URL", "GRAPH_EXPLORER_GRAPH_URL_BASE"},
|
||||
Destination: &cfg.GraphExplorer.GraphURLBase,
|
||||
},
|
||||
{
|
||||
|
||||
@@ -6,30 +6,6 @@ import (
|
||||
"github.com/urfave/cli/v2"
|
||||
)
|
||||
|
||||
// RootWithConfig applies cfg to the root flagset
|
||||
func RootWithConfig(cfg *config.Config) []cli.Flag {
|
||||
return []cli.Flag{
|
||||
&cli.StringFlag{
|
||||
Name: "log-level",
|
||||
Usage: "Set logging level",
|
||||
EnvVars: []string{"GRAPH_EXPLORER_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
&cli.BoolFlag{
|
||||
Name: "log-pretty",
|
||||
Usage: "Enable pretty logging",
|
||||
EnvVars: []string{"GRAPH_EXPLORER_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
&cli.BoolFlag{
|
||||
Name: "log-color",
|
||||
Usage: "Enable colored logging",
|
||||
EnvVars: []string{"GRAPH_EXPLORER_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
// HealthWithConfig applies cfg to the root flagset
|
||||
func HealthWithConfig(cfg *config.Config) []cli.Flag {
|
||||
return []cli.Flag{
|
||||
|
||||
@@ -17,35 +17,35 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "GRAPH_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "GRAPH_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "GRAPH_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_LOG_FILE", "OCIS_LOG_FILE"},
|
||||
EnvVars: []string{"OCIS_LOG_FILE", "GRAPH_LOG_FILE"},
|
||||
Destination: &cfg.Log.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "GRAPH_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "GRAPH_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "GRAPH_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "GRAPH_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
@@ -81,7 +81,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.HTTP.Namespace,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_SPACES_WEBDAV_BASE", "OCIS_URL"},
|
||||
EnvVars: []string{"OCIS_URL", "GRAPH_SPACES_WEBDAV_BASE"},
|
||||
Destination: &cfg.Spaces.WebDavBase,
|
||||
},
|
||||
{
|
||||
@@ -93,7 +93,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.Spaces.DefaultQuota,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"GRAPH_JWT_SECRET", "OCIS_JWT_SECRET"},
|
||||
EnvVars: []string{"OCIS_JWT_SECRET", "GRAPH_JWT_SECRET"},
|
||||
Destination: &cfg.TokenManager.JWTSecret,
|
||||
},
|
||||
{
|
||||
|
||||
@@ -13,19 +13,19 @@ func StructMappings(cfg *Config) []shared.EnvBinding {
|
||||
func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
return []shared.EnvBinding{
|
||||
{
|
||||
EnvVars: []string{"IDP_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "IDP_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"IDP_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "IDP_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"IDP_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "IDP_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"IDP_LOG_FILE", "OCIS_LOG_FILE"},
|
||||
EnvVars: []string{"OCIS_LOG_FILE", "IDP_LOG_FILE"},
|
||||
Destination: &cfg.Log.File,
|
||||
},
|
||||
{
|
||||
@@ -33,19 +33,19 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"IDP_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "IDP_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"IDP_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "IDP_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"IDP_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "IDP_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"IDP_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "IDP_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
@@ -141,7 +141,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.HTTP.TLSKey,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"IDP_ISS", "OCIS_URL"}, // IDP_ISS takes precedence over OCIS_URL
|
||||
EnvVars: []string{"OCIS_URL", "IDP_ISS"}, // IDP_ISS takes precedence over OCIS_URL
|
||||
Destination: &cfg.IDP.Iss,
|
||||
},
|
||||
{
|
||||
|
||||
+12
-12
@@ -13,19 +13,19 @@ func StructMappings(cfg *Config) []shared.EnvBinding {
|
||||
func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
return []shared.EnvBinding{
|
||||
{
|
||||
EnvVars: []string{"OCS_LOG_FILE", "OCIS_LOG_FILE"},
|
||||
EnvVars: []string{"OCIS_LOG_FILE", "OCS_LOG_FILE"},
|
||||
Destination: &cfg.Log.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCS_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "OCS_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCS_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "OCS_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCS_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "OCS_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
@@ -33,19 +33,19 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCS_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "OCS_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCS_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "OCS_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCS_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "OCS_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCS_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "OCS_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
@@ -85,7 +85,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.HTTP.Root,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCS_JWT_SECRET", "OCIS_JWT_SECRET"},
|
||||
EnvVars: []string{"OCIS_JWT_SECRET", "OCS_JWT_SECRET"},
|
||||
Destination: &cfg.TokenManager.JWTSecret,
|
||||
},
|
||||
{
|
||||
@@ -97,15 +97,15 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.RevaAddress,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCS_MACHINE_AUTH_API_KEY", "OCIS_MACHINE_AUTH_API_KEY"},
|
||||
EnvVars: []string{"OCIS_MACHINE_AUTH_API_KEY", "OCS_MACHINE_AUTH_API_KEY"},
|
||||
Destination: &cfg.MachineAuthAPIKey,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCS_IDM_ADDRESS", "OCIS_URL"},
|
||||
EnvVars: []string{"OCIS_URL", "OCS_IDM_ADDRESS"},
|
||||
Destination: &cfg.IdentityManagement.Address,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCS_STORAGE_USERS_DRIVER", "STORAGE_USERS_DRIVER"},
|
||||
EnvVars: []string{"STORAGE_USERS_DRIVER", "OCS_STORAGE_USERS_DRIVER"},
|
||||
Destination: &cfg.StorageUsersDriver,
|
||||
},
|
||||
}
|
||||
|
||||
@@ -24,19 +24,19 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
return []shared.EnvBinding{
|
||||
// Logging
|
||||
{
|
||||
EnvVars: []string{"PROXY_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "PROXY_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"PROXY_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "PROXY_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"PROXY_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "PROXY_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"PROXY_LOG_FILE", "OCIS_LOG_FILE"},
|
||||
EnvVars: []string{"OCIS_LOG_FILE", "PROXY_LOG_FILE"},
|
||||
Destination: &cfg.Log.File,
|
||||
},
|
||||
|
||||
@@ -54,19 +54,19 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
|
||||
// Tracing
|
||||
{
|
||||
EnvVars: []string{"PROXY_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "PROXY_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"PROXY_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "PROXY_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"PROXY_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "PROXY_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"PROXY_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "PROXY_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
@@ -124,7 +124,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.HTTP.TLS,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"PROXY_JWT_SECRET", "OCIS_JWT_SECRET"},
|
||||
EnvVars: []string{"OCIS_JWT_SECRET", "PROXY_JWT_SECRET"},
|
||||
Destination: &cfg.TokenManager.JWTSecret,
|
||||
},
|
||||
|
||||
@@ -137,7 +137,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.InsecureBackends,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"PROXY_OIDC_ISSUER", "OCIS_URL"},
|
||||
EnvVars: []string{"OCIS_URL", "PROXY_OIDC_ISSUER"},
|
||||
Destination: &cfg.OIDC.Issuer,
|
||||
},
|
||||
{
|
||||
@@ -173,7 +173,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.AccountBackend,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"PROXY_MACHINE_AUTH_API_KEY", "OCIS_MACHINE_AUTH_API_KEY"},
|
||||
EnvVars: []string{"OCIS_MACHINE_AUTH_API_KEY", "PROXY_MACHINE_AUTH_API_KEY"},
|
||||
Destination: &cfg.MachineAuthAPIKey,
|
||||
},
|
||||
// there are 2 missing bindings:
|
||||
|
||||
@@ -13,15 +13,15 @@ func StructMappings(cfg *Config) []shared.EnvBinding {
|
||||
func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
return []shared.EnvBinding{
|
||||
{
|
||||
EnvVars: []string{"SETTINGS_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "SETTINGS_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"SETTINGS_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "SETTINGS_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"SETTINGS_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "SETTINGS_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
@@ -29,19 +29,19 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"SETTINGS_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "SETTINGS_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"SETTINGS_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "SETTINGS_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"SETTINGS_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "SETTINGS_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"SETTINGS_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "SETTINGS_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
@@ -101,7 +101,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.Service.DataPath,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"SETTINGS_JWT_SECRET", "OCIS_JWT_SECRET"},
|
||||
EnvVars: []string{"OCIS_JWT_SECRET", "SETTINGS_JWT_SECRET"},
|
||||
Destination: &cfg.TokenManager.JWTSecret,
|
||||
},
|
||||
}
|
||||
|
||||
@@ -103,7 +103,7 @@ func FrontendWithConfig(cfg *config.Config) []cli.Flag {
|
||||
Name: "public-url",
|
||||
Value: flags.OverrideDefaultString(cfg.Reva.Frontend.PublicURL, "https://localhost:9200"),
|
||||
Usage: "URL to use for the storage service",
|
||||
EnvVars: []string{"STORAGE_FRONTEND_PUBLIC_URL", "OCIS_URL"}, // STORAGE_FRONTEND_PUBLIC_URL takes precedence over OCIS_URL
|
||||
EnvVars: []string{"OCIS_URL", "STORAGE_FRONTEND_PUBLIC_URL"}, // STORAGE_FRONTEND_PUBLIC_URL takes precedence over OCIS_URL
|
||||
Destination: &cfg.Reva.Frontend.PublicURL,
|
||||
},
|
||||
&cli.StringSliceFlag{
|
||||
|
||||
@@ -186,7 +186,7 @@ func GatewayWithConfig(cfg *config.Config) []cli.Flag {
|
||||
Name: "public-url",
|
||||
Value: flags.OverrideDefaultString(cfg.Reva.Frontend.PublicURL, "https://localhost:9200"),
|
||||
Usage: "URL to use for the storage service",
|
||||
EnvVars: []string{"STORAGE_FRONTEND_PUBLIC_URL", "OCIS_URL"}, // STORAGE_FRONTEND_PUBLIC_URL takes precedence over OCIS_URL
|
||||
EnvVars: []string{"OCIS_URL", "STORAGE_FRONTEND_PUBLIC_URL"}, // STORAGE_FRONTEND_PUBLIC_URL takes precedence over OCIS_URL
|
||||
Destination: &cfg.Reva.Frontend.PublicURL,
|
||||
},
|
||||
&cli.StringFlag{
|
||||
|
||||
@@ -18,19 +18,19 @@ func RootWithConfig(cfg *config.Config) []cli.Flag {
|
||||
&cli.StringFlag{
|
||||
Name: "log-level",
|
||||
Usage: "Set logging level",
|
||||
EnvVars: []string{"STORAGE_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "STORAGE_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
&cli.BoolFlag{
|
||||
Name: "log-pretty",
|
||||
Usage: "Enable pretty logging",
|
||||
EnvVars: []string{"STORAGE_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "STORAGE_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
&cli.BoolFlag{
|
||||
Name: "log-color",
|
||||
Usage: "Enable colored logging",
|
||||
EnvVars: []string{"STORAGE_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "STORAGE_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
}
|
||||
|
||||
@@ -13,35 +13,35 @@ func StructMappings(cfg *Config) []shared.EnvBinding {
|
||||
func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
return []shared.EnvBinding{
|
||||
{
|
||||
EnvVars: []string{"STORE_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "STORE_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"STORE_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "STORE_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"STORE_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "STORE_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"STORE_LOG_FILE", "OCIS_LOG_FILE"},
|
||||
EnvVars: []string{"OCIS_LOG_FILE", "STORE_LOG_FILE"},
|
||||
Destination: &cfg.Log.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"STORE_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "STORE_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"STORE_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "STORE_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"STORE_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "STORE_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"STORE_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "STORE_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
|
||||
@@ -13,19 +13,19 @@ func StructMappings(cfg *Config) []shared.EnvBinding {
|
||||
func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
return []shared.EnvBinding{
|
||||
{
|
||||
EnvVars: []string{"THUMBNAILS_LOG_FILE", "OCIS_LOG_FILE"},
|
||||
EnvVars: []string{"OCIS_LOG_FILE", "THUMBNAILS_LOG_FILE"},
|
||||
Destination: &cfg.Log.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"THUMBNAILS_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "THUMBNAILS_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"THUMBNAILS_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "THUMBNAILS_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"THUMBNAILS_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "THUMBNAILS_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
@@ -33,19 +33,19 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"THUMBNAILS_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "THUMBNAILS_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"THUMBNAILS_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "THUMBNAILS_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"THUMBNAILS_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "THUMBNAILS_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"THUMBNAILS_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "THUMBNAILS_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
|
||||
+11
-11
@@ -13,19 +13,19 @@ func StructMappings(cfg *Config) []shared.EnvBinding {
|
||||
func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
return []shared.EnvBinding{
|
||||
{
|
||||
EnvVars: []string{"WEB_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "WEB_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEB_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "WEB_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEB_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "WEB_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEB_LOG_FILE", "OCIS_LOG_FILE"},
|
||||
EnvVars: []string{"OCIS_LOG_FILE", "WEB_LOG_FILE"},
|
||||
Destination: &cfg.Log.File,
|
||||
},
|
||||
{
|
||||
@@ -33,19 +33,19 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEB_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "WEB_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEB_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "WEB_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEB_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "WEB_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEB_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "WEB_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
@@ -93,11 +93,11 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.Web.Path,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEB_UI_CONFIG_SERVER", "OCIS_URL"}, // WEB_UI_CONFIG_SERVER takes precedence over OCIS_URL
|
||||
EnvVars: []string{"OCIS_URL", "WEB_UI_CONFIG_SERVER"}, // WEB_UI_CONFIG_SERVER takes precedence over OCIS_URL
|
||||
Destination: &cfg.Web.Config.Server,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEB_UI_THEME_SERVER", "OCIS_URL"}, // WEB_UI_THEME_SERVER takes precedence over OCIS_URL
|
||||
EnvVars: []string{"OCIS_URL", "WEB_UI_THEME_SERVER"}, // WEB_UI_THEME_SERVER takes precedence over OCIS_URL
|
||||
Destination: &cfg.Web.ThemeServer,
|
||||
},
|
||||
{
|
||||
@@ -113,7 +113,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.Web.Config.OpenIDConnect.MetadataURL,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEB_OIDC_AUTHORITY", "OCIS_URL"}, // WEB_OIDC_AUTHORITY takes precedence over OCIS_URL
|
||||
EnvVars: []string{"OCIS_URL", "WEB_OIDC_AUTHORITY"}, // WEB_OIDC_AUTHORITY takes precedence over OCIS_URL
|
||||
Destination: &cfg.Web.Config.OpenIDConnect.Authority,
|
||||
},
|
||||
{
|
||||
|
||||
@@ -12,19 +12,19 @@ func RootWithConfig(cfg *config.Config) []cli.Flag {
|
||||
&cli.StringFlag{
|
||||
Name: "log-level",
|
||||
Usage: "Set logging level",
|
||||
EnvVars: []string{"WEB_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "WEB_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
&cli.BoolFlag{
|
||||
Name: "log-pretty",
|
||||
Usage: "Enable pretty logging",
|
||||
EnvVars: []string{"WEB_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "WEB_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
&cli.BoolFlag{
|
||||
Name: "log-color",
|
||||
Usage: "Enable colored logging",
|
||||
EnvVars: []string{"WEB_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "WEB_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
}
|
||||
|
||||
@@ -13,19 +13,19 @@ func StructMappings(cfg *Config) []shared.EnvBinding {
|
||||
func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
return []shared.EnvBinding{
|
||||
{
|
||||
EnvVars: []string{"WEBDAV_LOG_FILE", "OCIS_LOG_FILE"},
|
||||
EnvVars: []string{"OCIS_LOG_FILE", "WEBDAV_LOG_FILE"},
|
||||
Destination: &cfg.Log.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEBDAV_LOG_LEVEL", "OCIS_LOG_LEVEL"},
|
||||
EnvVars: []string{"OCIS_LOG_LEVEL", "WEBDAV_LOG_LEVEL"},
|
||||
Destination: &cfg.Log.Level,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEBDAV_LOG_PRETTY", "OCIS_LOG_PRETTY"},
|
||||
EnvVars: []string{"OCIS_LOG_PRETTY", "WEBDAV_LOG_PRETTY"},
|
||||
Destination: &cfg.Log.Pretty,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEBDAV_LOG_COLOR", "OCIS_LOG_COLOR"},
|
||||
EnvVars: []string{"OCIS_LOG_COLOR", "WEBDAV_LOG_COLOR"},
|
||||
Destination: &cfg.Log.Color,
|
||||
},
|
||||
{
|
||||
@@ -33,19 +33,19 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.File,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEBDAV_TRACING_ENABLED", "OCIS_TRACING_ENABLED"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENABLED", "WEBDAV_TRACING_ENABLED"},
|
||||
Destination: &cfg.Tracing.Enabled,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEBDAV_TRACING_TYPE", "OCIS_TRACING_TYPE"},
|
||||
EnvVars: []string{"OCIS_TRACING_TYPE", "WEBDAV_TRACING_TYPE"},
|
||||
Destination: &cfg.Tracing.Type,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEBDAV_TRACING_ENDPOINT", "OCIS_TRACING_ENDPOINT"},
|
||||
EnvVars: []string{"OCIS_TRACING_ENDPOINT", "WEBDAV_TRACING_ENDPOINT"},
|
||||
Destination: &cfg.Tracing.Endpoint,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"WEBDAV_TRACING_COLLECTOR", "OCIS_TRACING_COLLECTOR"},
|
||||
EnvVars: []string{"OCIS_TRACING_COLLECTOR", "WEBDAV_TRACING_COLLECTOR"},
|
||||
Destination: &cfg.Tracing.Collector,
|
||||
},
|
||||
{
|
||||
@@ -85,7 +85,7 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
Destination: &cfg.HTTP.Root,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"OCIS_PUBLIC_URL", "OCIS_URL"},
|
||||
EnvVars: []string{"OCIS_URL", "OCIS_PUBLIC_URL"},
|
||||
Destination: &cfg.OcisPublicURL,
|
||||
},
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user