Skip to content

Commit

Permalink
Merge pull request #67 from hanzala1234/master
Browse files Browse the repository at this point in the history
Add support for sealed secrets
  • Loading branch information
rasheedamir authored Mar 5, 2021
2 parents 5991102 + 6c67d71 commit 967e43b
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 0 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,5 +118,9 @@ To uninstall the chart:
| space.additionalLabels | Additional labels for Space Custom Resource | `{}` |
| space.annotations | Annotations for Space Custom Resource | `{}` |
| space.tenant | Tenant associated with Space Custom Resource | `""` |
| sealedSecret.enabled | Enable sealed secret | `false` |
| sealedSecret.additionalLabels | Labels for sealed secret | `{}` |
| sealedSecret.annotations | Annotations for sealed secret | `{}` |
| sealedSecret.files | Array of secret files with name and encrypted data contained in those files | `[]` |


30 changes: 30 additions & 0 deletions application/templates/sealedsecrets.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{{- if .Values.sealedSecret }}
{{- if .Values.sealedSecret.enabled }}
{{- range .Values.sealedSecret.files }}
apiVersion: bitnami.com/v1alpha1
kind: SealedSecret
metadata:
name: {{ .name }}
namespace: {{ template "application.namespace" $ }}
labels:
{{ include "application.labels.stakater" $ | indent 4 }}
{{ include "application.labels.chart" $ | indent 4 }}
{{- if $.Values.sealedSecret.additionalLabels }}
{{ toYaml $.Values.Sealedsecret.additionalLabels | indent 4 }}
{{- end }}
{{- if $.Values.Sealedsecret.annotations }}
annotations:
{{ toYaml $.Values.Sealedsecret.annotations | indent 4 }}
{{- end }}
spec:
encryptedData:
{{- range $key, $value := .encryptedData }}
{{ $key }}: {{ $value }}
{{- end }}
template:
metadata:
name: {{ .name }}
namespace: {{ template "application.namespace" $ }}
{{- end }}
{{- end }}
{{- end }}
10 changes: 10 additions & 0 deletions application/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -357,6 +357,16 @@ configMap:
# data:
# key1: value1
# key2: value2
sealedSecret:
enabled: false
additionalLabels:
# key: value
annotations:
# key: value
files:
# - name: example
# encryptedData:
# name: AgBghrdepGMKmp/rdtJrkBv/CWpJbtmoMsbKQ7QiZZ2kUoLeeTbrDnhmJY03kWKkNW4kN/sQRf6r1vvBEaR4nkHt5f/ayAeaH3NveI3bdb0xv/svvWjyjehwqwr/kNEAVWxRoUij0Y7MyIEAr4hnV2UnrhgvcjPJLNA8bK6spA+kuT328Vpyceyvnm6yArNn1aYlEckaFHrnculHWRpG73iRYxS5GWAY7EdkLXx7OLLWoopHtLcupklYyPfraJzPvBNZ5/PsyjlUBvoQbGV3cZlrdEj1WHj2S1RQ13ddf2WGtMHmY83t9B3LFZAZuA7BBt4rjludbwQm3/tJ5Kas1dDsSIRIIF7MTeum9YfRB8XUz8IxVKQ/JDskeynrWe3VzN/3HFVnv9GGFy+BCVXZKVU/roIRancz+nXkyoOHS722ZpBi53dfLItoS5dG+0EzArMTQzK/KXHz3b1rxp5oWWDNt3WggTiSg2zwy5ZR8VV2ToTDof6UrFmbCZv/kKriyxbVSxIo3KFnvuRiUZ5MwC0TNut4mW3LKyJfHqkUuLa1mYV6tKF58qBnoj/+JaibAIBEudT9hms5U52p7/jKmgHuop7XPEsz4OVwER//Vbv7X6ctoXtyPu6mZyOfOyJHM8Qj/H7/gwMBYhZHQ96DWrVmZOsWSRpZGJni4Xm7rgt2cFj6UtWv6lvl8aOi/HSZVC3TwWZ9mQrk

# Additional Secrets
secret:
Expand Down

0 comments on commit 967e43b

Please sign in to comment.