We need to update our saas-operator to create this new ExternalSecrets custom resources instead of current SecretDefinitons.
We will need to update current CRDs by adding to the fromVault spec:
Optional cluster-store (default value vault-mgmt, so no need to update current CRs with this new field)
Optional refreshInterval (default value 60s, so no need to update current CRs with this new field)
Removing from the vault path field the string secrets/data/ if set (not needed on ExternalSecrets), so no need to update current CRs with this existing field
That way current CRs will still work and change will be transparant.
As the target secrets will remain the same (the secret.spec.data won't change, so won't be triggered any deployment), to avoid the target secrets being removed temporarily and recreated by external-secrets-operator, it will be needed to:
Set secrets-manager operator to 0 pods
Deploy new saas-operator version
ExternalSecret will be created by saas-operator, and will adopt current target secret without doing changes on the secrets data (if it is configured correctly), which is the one used by saas-operator hashes:
It will add owner references to target secret (you can check it on argo now, an ExternalSecret resource which creates a Secret resource
Target secret labels will be merged with ExternalSecrets propagated labels and current ones from secrets-manager (last updated date, and updatedBy secrets-manager)
SecretDefinition won't be deleted, you need to manually edit each SecretDefinition by removing the metadata.finalizers field, then the SecretDefinition can be deleted
Delete manually secret-manager labels last updated date and updatedBy secrets-manager from target secrets
Set secrets-manager operator to 1 pod
Target secrets won't be updated anymore by secrets-manager
We are in the process of switching from
SecretDefinitons
(from secrets-manager) toExternalSecrets
(external-secrets operator).We need to update our saas-operator to create this new
ExternalSecrets
custom resources instead of currentSecretDefinitons
.We will need to update current CRDs by adding to the
fromVault
spec:vault-mgmt
, so no need to update current CRs with this new field)60s
, so no need to update current CRs with this new field)secrets/data/
if set (not needed on ExternalSecrets), so no need to update current CRs with this existing field That way current CRs will still work and change will be transparant.Example, from:
To:
As the target secrets will remain the same (the
secret.spec.data
won't change, so won't be triggered any deployment), to avoid the target secrets being removed temporarily and recreated by external-secrets-operator, it will be needed to:ExternalSecret
will be created by saas-operator, and will adopt current target secret without doing changes on the secrets data (if it is configured correctly), which is the one used by saas-operator hashes:ExternalSecret
resource which creates aSecret
resourceExternalSecrets
propagated labels and current ones from secrets-manager (last updated date
, andupdatedBy secrets-manager
)SecretDefinition
won't be deleted, you need to manually edit eachSecretDefinition
by removing themetadata.finalizers
field, then theSecretDefinition
can be deletedlast updated date
andupdatedBy secrets-manager
from target secrets