mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-01-06 04:09:40 -06:00
feat(groups): Only allow the "null" driver for multi-tenant setups
This commit is contained in:
committed by
Ralf Haferkamp
parent
736fb9db1f
commit
f096285769
@@ -2,6 +2,7 @@ package parser
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
|
||||
occfg "github.com/opencloud-eu/opencloud/pkg/config"
|
||||
"github.com/opencloud-eu/opencloud/pkg/shared"
|
||||
@@ -38,6 +39,9 @@ func Validate(cfg *config.Config) error {
|
||||
return shared.MissingJWTTokenError(cfg.Service.Name)
|
||||
}
|
||||
|
||||
if cfg.Commons.MultiTenantEnabled && cfg.Driver != "null" {
|
||||
return fmt.Errorf("Multi-tenant support is enabled. Only the 'null'-driver is supported by 'groups' service.")
|
||||
}
|
||||
if cfg.Drivers.LDAP.BindPassword == "" && cfg.Driver == "ldap" {
|
||||
return shared.MissingLDAPBindPassword(cfg.Service.Name)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user