add missing commands and unify service / namespace options
This commit is contained in:
+21
-21
@@ -19,11 +19,18 @@ type Debug struct {
|
||||
|
||||
// HTTP defines the available http configuration.
|
||||
type HTTP struct {
|
||||
Addr string `ocisConfig:"addr"`
|
||||
Root string `ocisConfig:"root"`
|
||||
TLSCert string `ocisConfig:"tls_cert"`
|
||||
TLSKey string `ocisConfig:"tls_key"`
|
||||
TLS bool `ocisConfig:"tls"`
|
||||
Addr string `ocisConfig:"addr"`
|
||||
Root string `ocisConfig:"root"`
|
||||
Namespace string `ocisConfig:"namespace"`
|
||||
TLSCert string `ocisConfig:"tls_cert"`
|
||||
TLSKey string `ocisConfig:"tls_key"`
|
||||
TLS bool `ocisConfig:"tls"`
|
||||
}
|
||||
|
||||
// Service defines the available service configuration.
|
||||
type Service struct {
|
||||
Name string `ocisConfig:"name"`
|
||||
Version string `ocisConfig:"version"`
|
||||
}
|
||||
|
||||
// Ldap defines the available LDAP configuration.
|
||||
@@ -41,13 +48,6 @@ type Ldap struct {
|
||||
Filter string `ocisConfig:"filter"`
|
||||
}
|
||||
|
||||
// Service defines the available service configuration.
|
||||
type Service struct {
|
||||
Name string `ocisConfig:"name"`
|
||||
Namespace string `ocisConfig:"namespace"`
|
||||
Version string `ocisConfig:"version"`
|
||||
}
|
||||
|
||||
// Tracing defines the available tracing configuration.
|
||||
type Tracing struct {
|
||||
Enabled bool `ocisConfig:"enabled"`
|
||||
@@ -125,11 +125,15 @@ func DefaultConfig() *Config {
|
||||
Addr: "127.0.0.1:9134",
|
||||
},
|
||||
HTTP: HTTP{
|
||||
Addr: "127.0.0.1:9130",
|
||||
Root: "/",
|
||||
TLSCert: path.Join(defaults.BaseDataPath(), "idp", "server.crt"),
|
||||
TLSKey: path.Join(defaults.BaseDataPath(), "idp", "server.key"),
|
||||
TLS: false,
|
||||
Addr: "127.0.0.1:9130",
|
||||
Root: "/",
|
||||
Namespace: "com.owncloud.web",
|
||||
TLSCert: path.Join(defaults.BaseDataPath(), "idp", "server.crt"),
|
||||
TLSKey: path.Join(defaults.BaseDataPath(), "idp", "server.key"),
|
||||
TLS: false,
|
||||
},
|
||||
Service: Service{
|
||||
Name: "idp",
|
||||
},
|
||||
Tracing: Tracing{
|
||||
Type: "jaeger",
|
||||
@@ -184,9 +188,5 @@ func DefaultConfig() *Config {
|
||||
UUIDAttributeType: "text",
|
||||
Filter: "(objectClass=posixaccount)",
|
||||
},
|
||||
Service: Service{
|
||||
Name: "idp",
|
||||
Namespace: "com.owncloud.web",
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
@@ -89,10 +89,10 @@ func structMappings(cfg *Config) []shared.EnvBinding {
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"IDP_HTTP_NAMESPACE"},
|
||||
Destination: &cfg.Service.Namespace,
|
||||
Destination: &cfg.HTTP.Namespace,
|
||||
},
|
||||
{
|
||||
EnvVars: []string{"IDP_NAME"},
|
||||
EnvVars: []string{"IDP_SERVICE_NAME"},
|
||||
Destination: &cfg.Service.Name,
|
||||
},
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user