mirror of
https://github.com/zalando/postgres-operator.git
synced 2026-10-09 15:16:37 +02:00
Include CREATEROLE to the list of allowed flags. (#365)
Previously it has been supported by the operator, but the validity check excluded it for no reason.
This commit is contained in:
+2
-1
@@ -78,7 +78,8 @@ func (c *Cluster) isSystemUsername(username string) bool {
|
|||||||
|
|
||||||
func isValidFlag(flag string) bool {
|
func isValidFlag(flag string) bool {
|
||||||
for _, validFlag := range []string{constants.RoleFlagSuperuser, constants.RoleFlagLogin, constants.RoleFlagCreateDB,
|
for _, validFlag := range []string{constants.RoleFlagSuperuser, constants.RoleFlagLogin, constants.RoleFlagCreateDB,
|
||||||
constants.RoleFlagInherit, constants.RoleFlagReplication, constants.RoleFlagByPassRLS} {
|
constants.RoleFlagInherit, constants.RoleFlagReplication, constants.RoleFlagByPassRLS,
|
||||||
|
constants.RoleFlagCreateRole} {
|
||||||
if flag == validFlag || flag == "NO"+validFlag {
|
if flag == validFlag || flag == "NO"+validFlag {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user