Skip to content

Commit

Permalink
[surveyor helm] add support for nkey in the same way as credentials (#…
Browse files Browse the repository at this point in the history
…832)

Add support for specification of an nkey file for auth. Everything is exactly identical to credentials.
  • Loading branch information
0xflatheadfred authored Nov 27, 2023
1 parent cae6388 commit bf992b2
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
14 changes: 14 additions & 0 deletions helm/charts/surveyor/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,10 @@ spec:
- --creds=/creds/{{ .secret.key }}
{{- end }}

{{- with .nkey }}
- --nkey=/nkey/{{ .secret.key }}
{{- end }}

{{- with .servers }}
- -s={{ . }}
{{- end }}
Expand Down Expand Up @@ -86,6 +90,11 @@ spec:
mountPath: /creds/
readOnly: true
{{- end }}
{{- with .Values.config.nkey }}
- name: nkey
mountPath: /nkey/
readOnly: true
{{- end }}
{{- with .Values.config.tls }}
- name: {{ .secret.name }}-volume
mountPath: /etc/nats-certs/clients/
Expand Down Expand Up @@ -116,6 +125,11 @@ spec:
secret:
secretName: {{ .secret.name }}
{{- end }}
{{- with .Values.config.nkey }}
- name: nkey
secret:
secretName: {{ .secret.name }}
{{- end }}
{{- with .Values.config.tls }}
- name: {{ .secret.name }}-volume
secret:
Expand Down
5 changes: 5 additions & 0 deletions helm/charts/surveyor/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,11 @@ config:
# name: nats-sys-creds
# key: sys.creds

# nkey:
# secret:
# name: nats-sys-nkey
# key: sys.nkey

# Required for NATS mutual TLS
# tls:
# secret:
Expand Down

0 comments on commit bf992b2

Please sign in to comment.