You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Now db-operator is adding labels to all the k8s resource that are used by it, and because of this change, we now can be sure that it's not possible to use the same secret/configmap/etc by several databases in the same time. Also, this change will let us implement templated credentials for DbUsers.
But why are we bumping a major version?
Because a huge part of the database controller was re-written, and what's more important, the reconciliation logic was changed, that might lead to unexpected (at first) behaviour. Previously, db-operator was setting OwnerReferences when k8s resource were created, and it was not a part of regular reconciliation, now, when you change the spec.cleanup value, owner references will be updated too. Because of that, it's possible that db-operator will take over the control over resources that were not created by it. For example, when a secret/database-credentials was present in the cluster before a database/postgres-db was created, and then a Database is with spec.secretReference set to database-credentials and spec.cleanup - to true. This setup will make db-operator add owner references to the secret and from now on the Database is "the owner" of the Secret. That means that once the Database is removed from the cluster, Kubernetes will remove the secret as well.
If you need to have cleanup set to true, but would like something to be preserved after Database removing, you might want to set an additional owner reference on that object.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Version v2.0.0 is released
What's Changed
Notes
Now db-operator is adding labels to all the k8s resource that are used by it, and because of this change, we now can be sure that it's not possible to use the same
secret/configmap/etc
by several databases in the same time. Also, this change will let us implement templated credentials for DbUsers.But why are we bumping a major version?
Because a huge part of the database controller was re-written, and what's more important, the reconciliation logic was changed, that might lead to unexpected (at first) behaviour. Previously, db-operator was setting OwnerReferences when k8s resource were created, and it was not a part of regular reconciliation, now, when you change the
spec.cleanup
value, owner references will be updated too. Because of that, it's possible that db-operator will take over the control over resources that were not created by it. For example, when asecret/database-credentials
was present in the cluster before adatabase/postgres-db
was created, and then aDatabase
is withspec.secretReference
set todatabase-credentials
andspec.cleanup
- totrue
. This setup will make db-operator add owner references to the secret and from now on theDatabase
is "the owner" of theSecret
. That means that once theDatabase
is removed from the cluster, Kubernetes will remove the secret as well.If you need to have
cleanup
set to true, but would like something to be preserved afterDatabase
removing, you might want to set an additional owner reference on that object.Full Changelog: v1.17.0...v2.0.0
This discussion was created from the release v2.0.0.
Beta Was this translation helpful? Give feedback.
All reactions