We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ccb52c0 commit 64215b0Copy full SHA for 64215b0
pkg/cluster/k8sres.go
@@ -1928,7 +1928,7 @@ func (c *Cluster) generateSingleUserSecret(pgUser spec.PgUser) *v1.Secret {
1928
1929
// if secret lives in another namespace we cannot set ownerReferences
1930
var ownerReferences []metav1.OwnerReference
1931
- if c.Config.OpConfig.EnableCrossNamespaceSecret && strings.Contains(username, ".") {
+ if c.Config.OpConfig.EnableCrossNamespaceSecret && c.Postgresql.ObjectMeta.Namespace != pgUser.Namespace {
1932
ownerReferences = nil
1933
} else {
1934
ownerReferences = c.ownerReferences()
0 commit comments