Skip to content

Commit 94ec399

Browse files
committed
do not create htpasswd on the fly in template since the operator goes crazy
1 parent 163c844 commit 94ec399

File tree

4 files changed

+6
-4
lines changed

4 files changed

+6
-4
lines changed

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.1.7-rc.6
1+
0.1.7-rc.7

helm-charts/kuberoapp/templates/ingress.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ metadata:
2222
{{- with .Values.ingress.annotations }}
2323
{{- toYaml . | nindent 4 }}
2424
{{- end }}
25-
{{- if gt (len .Values.basicAuth.accounts) 0 }}
25+
{{- if .Values.basicAuth.enabled }}
2626
nginx.ingress.kubernetes.io/auth-secret: {{ include "kuberoapp.fullname" . }}-htpasswd
2727
nginx.ingress.kubernetes.io/auth-type: basic
2828
nginx.ingress.kubernetes.io/auth-realm: {{ .Values.basicAuth.realm | quote }}

helm-charts/kuberoapp/templates/secret-basic-auth.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@
22
{{- $accounts := .Values.basicAuth.accounts }}
33
{{- $val := "" }}
44
{{- range $account := $accounts }}
5-
{{- $hash := htpasswd $account.user $account.pass }}
6-
{{- $val = printf "%s%s\n" $val $hash }}
5+
{{- $val = printf "%s%s\n" $val $account.hash }}
76
{{- end }}
87
apiVersion: v1
98
kind: Secret

helm-charts/kuberoapp/values.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -159,12 +159,15 @@ resources: {}
159159
# memory: 128Mi
160160

161161
basicAuth:
162+
enabled: false
162163
realm: "Protected"
163164
accounts: []
164165
#- user: foo
165166
# pass: bar
167+
# hash: ""
166168
#- user: bar
167169
# pass: foo
170+
# hash: ""
168171

169172
autoscaling:
170173
enabled: false

0 commit comments

Comments
 (0)