git.iko.soy/typeable/octopod
on master help sign in
Helm3 fixes (#45)

* remove test values file * rearrange secrets to avoid double password generation

commit3919687c13dbcc7bef847d0ab8dc3f1784f7ec12 authorAlex-Sizov <45825279+Alex-Sizov@users.noreply.github.com> dateWed 12 May 2021, 18:37 (5 years ago) parent291c3c4
4 files changed+12−119
charts/helm3/octopod/templates/_helpers.tpl−4 charts/helm3/octopod/templates/nginx-configmap.yaml+12−1 charts/helm3/octopod/templates/octopod-basic-auth-secret.yaml−10 charts/helm3/octopod/values-test.yaml−104
charts/helm3/octopod/templates/_helpers.tpl−4
@@ -69,10 +69,6 @@ Create the name of the service account to use
6969{{- printf "%s-app-auth-secret" (include "octopod.fullname" .) }}
7070{{- end }}
7171
72−{{- define "octopodAppAuthPassword" -}}
73−{{- randAlphaNum 32 }}
74−{{- end }}
75−
7672{{- define "httpScheme" -}}
7773{{- if .Values.ingress.tls.enabled -}}
7874https
charts/helm3/octopod/templates/nginx-configmap.yaml+12−1
@@ -1,3 +1,4 @@
1+{{- $octopodAppAuthPassword := randAlphaNum 32 -}}
12apiVersion: v1
23kind: ConfigMap
34metadata:
@@ -17,8 +18,18 @@ data:
1718 {
1819 "app_url": "{{ printf "%s://%s" (include "httpScheme" .) .Values.ingress.app.host}}",
1920 "ws_url": "{{ printf "%s://%s" (include "wsScheme" .) .Values.ingress.ws.host}}",
20− "app_auth": "Basic {{ printf "octopod:%s" (include "octopodAppAuthPassword" .) | b64enc }}",
21+ "app_auth": "Basic {{ printf "octopod:%s" $octopodAppAuthPassword | b64enc }}",
2122
2223 "kubernetes_dashboard_url_template": null
2324
2425 }
26+---
27+apiVersion: v1
28+kind: Secret
29+type: Opaque
30+metadata:
31+ name: {{ include "octopodAppAuthSecretName" . }}
32+ labels:
33+ {{- include "octopod.labels" . | nindent 4 }}
34+data:
35+ auth: {{ htpasswd "octopod" $octopodAppAuthPassword | b64enc }}
charts/helm3/octopod/templates/octopod-basic-auth-secret.yamldeleted−10
@@ -1,10 +0,0 @@
1−apiVersion: v1
2−kind: Secret
3−type: Opaque
4−metadata:
5− name: {{ include "octopodAppAuthSecretName" . }}
6− labels:
7− {{- include "octopod.labels" . | nindent 4 }}
8−data:
9− auth: {{ htpasswd "octopod" (include "octopodAppAuthPassword" . ) | b64enc }}
10−
charts/helm3/octopod/values-test.yamldeleted−104
@@ -1,104 +0,0 @@
1−# Default values for octopod.
2−# This is a YAML-formatted file.
3−# Declare variables to be passed into your templates.
4−
5−replicaCount: 1
6−
7−image:
8− repository: typeable/octopod
9− pullPolicy: IfNotPresent
10− # Overrides the image tag whose default is the chart appVersion.
11− tag: ""
12−
13−imagePullSecrets: []
14−nameOverride: ""
15−fullnameOverride: ""
16−
17−serviceAccount:
18− # Specifies whether a service account should be created
19− create: true
20− # Annotations to add to the service account
21− annotations: {}
22− # The name of the service account to use.
23− # If not set and create is true, a name is generated using the fullname template
24− name: ""
25−rbac:
26− create: true
27−podAnnotations: {}
28−
29−podSecurityContext: {}
30− # fsGroup: 2000
31−
32−securityContext:
33− runAsUser: 1000
34− runAsGroup: 1000
35− # capabilities:
36− # drop:
37− # - ALL
38− # readOnlyRootFilesystem: true
39− # runAsNonRoot: true
40−
41−service:
42− type: ClusterIP
43− ports:
44− powerApp: 4443
45− ui: 80
46− app: 4000
47− ws: 4020
48−
49−ingress:
50− enabled: true
51− ingressClass: nginx
52− tls:
53− enabled: true
54− clusterIssuer: letsencrypt
55− powerApp:
56− host: octopod-powerapp.sizov-test.thebestagent.pro
57− annotations: {}
58− ui:
59− host: octopod.sizov-test.thebestagent.pro
60− annotations: {}
61− app:
62− host: octopod-app.sizov-test.thebestagent.pro
63− annotations: {}
64− ws:
65− host: octopod-ws.sizov-test.thebestagent.pro
66− annotations: {}
67−
68−resources:
69− limits:
70− cpu: 200m
71− memory: 512Mi
72− requests:
73− cpu: 200m
74− memory: 256Mi
75−
76−nodeSelector: {}
77−
78−tolerations: []
79−
80−affinity: {}
81−
82−octopod:
83− certsConfigMapName: octopod-certs
84− projectName: Octopod
85− deploymentNamespace: octopod-deployment
86− baseDomain: "sizov-test.thebestagent.pro"
87− statusUpdateTimeout: 600
88− archiveRetention: 1209600
89− migrations:
90− enabled: true
91−controlScripts:
92− image:
93− repository: typeable/octopod-helm-example
94− pullPolicy: IfNotPresent
95− tag: 1.1
96−sqitch:
97− image:
98− repository: typeable/sqitch
99− pullPolicy: IfNotPresent
100− tag: v2.0.0
101−postgresql:
102− enabled: true
103− postgresqlUsername: octopod
104− postgresqlDatabase: octopod