Skip to content
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

[FEATURE] Get secret by tag/tag values #563

Open
tiwood opened this issue Jul 4, 2023 · 0 comments
Open

[FEATURE] Get secret by tag/tag values #563

tiwood opened this issue Jul 4, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@tiwood
Copy link

tiwood commented Jul 4, 2023

Is your feature request related to a problem? Please describe.
We enforce randomness on our resources. Lets assume we generate a SQL database called sql-37fjs29sw and some secrets along with the db sql-37fjs29sw. If we would re-create the database or deploy to a different stage, the random part of the name would change and we have to update the definition of AKV2AKS secret.

Describe the solution you'd like
If we could select secrets by tags we could tag the secrets accordingly and deploy the same AKV2AKS manifest in all stages without changing the secret name.

Example:

apiVersion: spv.no/v2beta1 # custom resource definition version
kind: AzureKeyVaultSecret
metadata:
  name: foo
  namespace: default
spec:
  vault:
    name: mykv
    object:
      tags:
        - name: app
          value: myapp1
      type: secret
  output: # ignored by env injector, required by controller to output kubernetes secret
    transform: # optional transformers executed in listed order
      - trim # optional - trims empty space
      - base64encode # optional - encode to base64
      - base64decode # optional - decode from base64
    secret: 
      name: <name of the kubernetes secret to create>
      type: <optional - kubernetes secret type - defaults to opaque>
      dataKey: <required when type is opaque - name of the kubernetes secret data key to assign value to - ignored for all other types>
      chainOrder: <optional - used when server certificate is at the end of the chain - set to ensureserverfirst>
    configMap:
      name: <name of the kubernetes secret to create>
      dataKey: <name of the kubernetes config map data key to assign value to>
@tiwood tiwood added the enhancement New feature or request label Jul 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant