jenkins-x-plugins / jx-secret

a binary plugin for working with Kubernetes External Secrets
Apache License 2.0
17 stars 24 forks source link

support a default template mapping data entry using to templating #351

Open jstrachan opened 3 years ago

jstrachan commented 3 years ago

it would be nice if we supported a defaults template entry using to templating.

e.g. something like:

# .jx/secret/mapping/secret-mappings.yaml
apiVersion: secret.jenkins-x.io/v1alpha1
kind: SecretMapping
spec:
  defaults:
    backendType: vault
    mappingTemplate: 
      key:  "secret/data/{{ .Namespace }}/{{ .Chart }}/{{ .Secret }}/{{ . Entry }}"

so that folks can configure via go template expressions the default values like key/property based on template expressions