Skip to content

Commit

Permalink
feat: ability to use existingSecret for psql (#148)
Browse files Browse the repository at this point in the history
  • Loading branch information
davelosert authored Aug 31, 2020
1 parent d2705c3 commit 8c02d7a
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 14 deletions.
4 changes: 2 additions & 2 deletions sentry/templates/deployment-sentry-cron.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ spec:
- name: POSTGRES_PASSWORD
valueFrom:
secretKeyRef:
name: {{ include "sentry.postgresql.fullname" . }}
key: postgresql-password
name: {{ default (include "sentry.postgresql.fullname" .) .Values.postgresql.existingSecret }}
key: {{ default "postgresql-password" .Values.postgresql.existingSecretKey }}
{{- end }}
{{ if eq .Values.filestore.backend "gcs" }}
- name: GOOGLE_APPLICATION_CREDENTIALS
Expand Down
4 changes: 2 additions & 2 deletions sentry/templates/deployment-sentry-ingest-consumer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,8 @@ spec:
- name: POSTGRES_PASSWORD
valueFrom:
secretKeyRef:
name: {{ include "sentry.postgresql.fullname" . }}
key: postgresql-password
name: {{ default (include "sentry.postgresql.fullname" .) .Values.postgresql.existingSecret }}
key: {{ default "postgresql-password" .Values.postgresql.existingSecretKey }}
{{- end }}
{{ if eq .Values.filestore.backend "gcs" }}
- name: GOOGLE_APPLICATION_CREDENTIALS
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@ spec:
- name: POSTGRES_PASSWORD
valueFrom:
secretKeyRef:
name: {{ include "sentry.postgresql.fullname" . }}
key: postgresql-password
name: {{ default (include "sentry.postgresql.fullname" .) .Values.postgresql.existingSecret }}
key: {{ default "postgresql-password" .Values.postgresql.existingSecretKey }}
{{- end }}
{{ if eq .Values.filestore.backend "gcs" }}
- name: GOOGLE_APPLICATION_CREDENTIALS
Expand Down
4 changes: 2 additions & 2 deletions sentry/templates/deployment-sentry-web.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ spec:
- name: POSTGRES_PASSWORD
valueFrom:
secretKeyRef:
name: {{ include "sentry.postgresql.fullname" . }}
key: postgresql-password
name: {{ default (include "sentry.postgresql.fullname" .) .Values.postgresql.existingSecret }}
key: {{ default "postgresql-password" .Values.postgresql.existingSecretKey }}
{{- end }}
{{ if eq .Values.filestore.backend "gcs" }}
- name: GOOGLE_APPLICATION_CREDENTIALS
Expand Down
4 changes: 2 additions & 2 deletions sentry/templates/deployment-sentry-worker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,8 @@ spec:
- name: POSTGRES_PASSWORD
valueFrom:
secretKeyRef:
name: {{ include "sentry.postgresql.fullname" . }}
key: postgresql-password
name: {{ default (include "sentry.postgresql.fullname" .) .Values.postgresql.existingSecret }}
key: {{ default "postgresql-password" .Values.postgresql.existingSecretKey }}
{{- end }}
{{ if eq .Values.filestore.backend "gcs" }}
- name: GOOGLE_APPLICATION_CREDENTIALS
Expand Down
4 changes: 2 additions & 2 deletions sentry/templates/hooks/sentry-db-init.job.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ spec:
- name: POSTGRES_PASSWORD
valueFrom:
secretKeyRef:
name: {{ include "sentry.postgresql.fullname" . }}
key: postgresql-password
name: {{ default (include "sentry.postgresql.fullname" .) .Values.postgresql.existingSecret }}
key: {{ default "postgresql-password" .Values.postgresql.existingSecretKey }}
{{- end }}
{{- if .Values.hooks.dbInit.env }}
{{ toYaml .Values.hooks.dbInit.env | indent 8 }}
Expand Down
4 changes: 2 additions & 2 deletions sentry/templates/hooks/user-create.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@ spec:
- name: POSTGRES_PASSWORD
valueFrom:
secretKeyRef:
name: {{ include "sentry.postgresql.fullname" . }}
key: postgresql-password
name: {{ default (include "sentry.postgresql.fullname" .) .Values.postgresql.existingSecret }}
key: {{ default "postgresql-password" .Values.postgresql.existingSecretKey }}
{{- end }}
{{- if .Values.hooks.dbInit.env }}
{{ toYaml .Values.hooks.dbInit.env | indent 8 }}
Expand Down

0 comments on commit 8c02d7a

Please sign in to comment.