Skip to content
This repository has been archived by the owner on Feb 22, 2022. It is now read-only.

Commit

Permalink
fix: do not fail user-create container when user already exists (#20106)
Browse files Browse the repository at this point in the history
Signed-off-by: wilmardo <info@wilmardenouden.nl>
  • Loading branch information
wilmardo authored and k8s-ci-robot committed Jan 14, 2020
1 parent b7be614 commit 4c39ce9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion stable/sentry/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v1
description: Sentry is a cross-platform crash reporting and aggregation platform.
name: sentry
version: 3.2.1
version: 3.2.2
appVersion: 9.1.2
keywords:
- debugging
Expand Down
5 changes: 4 additions & 1 deletion stable/sentry/templates/hooks/user-create.job.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,10 @@ spec:
containers:
- name: user-create-job
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
command: ["sentry","createuser","--no-input","--email", "{{ .Values.user.email }}", "--superuser","--password","$(SENTRY_USER_PASSWORD)"]
command: ["/bin/bash"]
args:
- "-c"
- "export output=$(sentry createuser --no-input --email {{ .Values.user.email }} --superuser --password $SENTRY_USER_PASSWORD) || if echo $output | grep -q 'already exists'; then exit 0; else exit 1; fi"
env:
- name: SENTRY_SECRET_KEY
valueFrom:
Expand Down

0 comments on commit 4c39ce9

Please sign in to comment.