feat: Add format-specific annotations to override secret file names#572
Merged
feat: Add format-specific annotations to override secret file names#572
Conversation
nightkr
reviewed
Mar 18, 2025
Member
Author
|
The path traversal check will be replaced in a followup PR by a better suited solution which leverages capabilities-based filesystem operations. See #572 (comment). |
Path::canonicalize will return an error if the path does not exist. The path we are checking obviously doesn't exist yet, because we want to prevent path traversals and the file at that path will only exist after we are done with the check. So using canonicalize does not work in this use-case.
nightkr
reviewed
Mar 31, 2025
nightkr
previously approved these changes
Mar 31, 2025
Contributor
|
LGTM, assuming tests pass on your end. |
Contributor
|
Actually - just noticed that you forgot to add it to the changelog. |
Member
Author
|
You are right, I will add it right away. |
nightkr
approved these changes
Mar 31, 2025
Member
|
Can you please link docs and add a release note snippet? |
Member
Author
|
Link to docs: https://docs.stackable.tech/home/nightly/secret-operator/volume/ Release NotesAdd support for format-specific annotations to override secret file names.
Names can be customized using secret volume annotations which are listed xref:secret-operator:volume.adoc[in our documentation].
See https://github.com/stackabletech/secret-operator/pull/572[secret-operator#572]. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds support to customize the secret file names using
secrets.stackable.techannotations on the volume. The following attributes were added:secrets.stackable.tech/format.tls-pkcs12.keystore-namesecrets.stackable.tech/format.tls-pkcs12.truststore-namesecrets.stackable.tech/format.tls-pem.cert-namesecrets.stackable.tech/format.tls-pem.key-namesecrets.stackable.tech/format.tls-pem.ca-nameThis came up in demo testing during the 25.3.0 SPD release, see stackabletech/demos#157 (comment).
This PR adds a new test dimension which is used in the
tlstests. All adjusted tests pass: