mirror of
https://github.com/zalando/postgres-operator.git
synced 2026-09-30 20:11:54 +02:00
create global default privileges in the appropriate prepared databases (#1421)
This commit is contained in:
@@ -661,6 +661,9 @@ func (c *Cluster) syncDatabases() error {
|
||||
|
||||
// set default privileges for prepared database
|
||||
for _, preparedDatabase := range preparedDatabases {
|
||||
if err := c.initDbConnWithName(preparedDatabase); err != nil {
|
||||
return fmt.Errorf("could not init database connection to %s", preparedDatabase)
|
||||
}
|
||||
if err = c.execAlterGlobalDefaultPrivileges(preparedDatabase+constants.OwnerRoleNameSuffix, preparedDatabase); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user