-
-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Version 0.4.0 not working #45
Comments
Thanks for reporting! Unfortunately, this has never reproduced in my own environment. |
We noticed the same behavior when updating from 0.3.3 to 0.5.2. Apparently AWSSecrets without versionId cause the secret update process silently to "fail" here https://github.com/mumoshu/aws-secret-operator/blob/main/controllers/awssecret_controller.go#L146:L182 VersionId is required given the instructions on readme and the open API schema, but aws-secret-operator won't output errors even if it's missing, and empty secret object is created, which is what I assume happened with @gagarinfan |
@hhamalai Ah! Thank you so much for pointing it out. It does seem like I have unintentionally broken the existing "undocumented" behavior. Yes, my intention was always to force providing versionId, so that folks would never try to use it to "auto-update" the secret which doesn't usually trigger e.g. a rolling-update of dependent k8s deployments/pods. I'm very unsure what's the "correct" way forward. Your comment is welcomed. For me- I'm slightly inclined to make VersionId optional officially, making it a documented behavior, so that folks can actually use it to auto-update secrets. Almost certainly the updated documentation should suggest combining the operator with something like reloader to propagate changes down to the consumers of the secrets. WDYT? |
FWIW I think that's a valid approach, this could be enforced by modifying diff --git a/deploy/crds/mumoshu.github.io_awssecrets.yaml b/deploy/crds/mumoshu.github.io_awssecrets.yaml
index fb69ea7..5f36453 100644
--- a/deploy/crds/mumoshu.github.io_awssecrets.yaml
+++ b/deploy/crds/mumoshu.github.io_awssecrets.yaml
@@ -41,6 +41,7 @@ spec:
encoded using base64.
properties:
secretsManagerSecretRef:
+ required: ["secretId", "versionId"]
description: SecretsManagerSecretRef defines from which SecretsManager
Secret the Kubernetes secret is built See https://docs.aws.amazon.com/secretsmanager/latest/userguide/terms-concepts.html
for the concepts
@@ -71,6 +72,7 @@ spec:
and allows you to provide secret data as unencoded strings.
properties:
secretsManagerSecretRef:
+ required: ["secretId", "versionId"]
description: SecretsManagerSecretRef defines from which SecretsManager
Secret the Kubernetes secret is built See https://docs.aws.amazon.com/secretsmanager/latest/userguide/terms-concepts.html
for the concepts |
Hi! I've been using your operator (which is great and very useful) version
0.3.3
and after change to0.4.0
seems that it has stopped working both forstringDataFrom
anddataFrom
options. Latest version has support for base64 secrets (#43) which I'd like to use.Steps to reproduce (example for
stringDataFrom
option):debug-secret
with Secret Key:key
and Secret Value:value
debug-secret
with empty data field (I've deleted irrelevant lines):operator logs
I would be grateful for help
The text was updated successfully, but these errors were encountered: