@@ -13,13 +13,23 @@ metadata:
1313 chart : {{ template "common.chart" . }}
1414 release : {{ .Release.Name }}
1515 heritage : {{ .Release.Service }}
16+ {{- if (.Values.friendbot.deployment).deploymentAnnotations }}
17+ annotations :
18+ {{- range $key, $value := .Values.friendbot.deployment.deploymentAnnotations }}
19+ {{ $key }}: {{ $value | quote }}
20+ {{- end }}
21+ {{- end }}
1622spec :
1723 replicas : {{ .Values.friendbot.deployment.container.replicaCount }}
1824 selector :
1925 matchLabels :
2026 app : {{ template "common.fullname" . }}
2127 strategy :
28+ {{- if .Values.friendbot.deployment.strategy }}
29+ {{- toYaml .Values.friendbot.deployment.strategy | nindent 4 }}
30+ {{- else }}
2231 type : RollingUpdate
32+ {{- end }}
2333 template :
2434 metadata :
2535 labels :
@@ -50,18 +60,28 @@ spec:
5060 {{- end }}
5161 {{- end }}
5262 imagePullPolicy : {{ .Values.global.image.friendbot.pullPolicy }}
63+ ports :
64+ - containerPort : {{ .Values.friendbot.configmap.port | default 8000 }}
65+ protocol : TCP
66+ {{- with .Values.friendbot.deployment.container.startupProbe }}
67+ {{- $startupProbe := deepCopy . }}
68+ {{- if and (hasKey $startupProbe "tcpSocket") (kindIs "map" $startupProbe.tcpSocket) (not (hasKey $startupProbe.tcpSocket "port")) }}
69+ {{- $_ := set $startupProbe.tcpSocket "port" ($.Values.friendbot.configmap.port | default 8000) }}
70+ {{- end }}
5371 startupProbe :
54- tcpSocket :
55- port : {{ .Values.friendbot.deployment.container.startupProbe.tcpSocketPort }}
56- initialDelaySeconds : {{ .Values.friendbot.deployment.container.startupProbe.initialDelaySeconds }}
57- failureThreshold : {{ .Values.friendbot.deployment.container.startupProbe.failureThreshold }}
58- periodSeconds : {{ .Values.friendbot.deployment.container.startupProbe.periodSeconds }}
59- timeoutSeconds : {{ .Values.friendbot.deployment.container.startupProbe.timeoutSeconds }}
72+ {{- toYaml $startupProbe | nindent 10 }}
73+ {{- end }}
6074 volumeMounts :
61- - name : config-volume
75+ - name : friendbot-secret
76+ mountPath : /secret
77+ readOnly : true
78+ - name : friendbot-conf
6279 mountPath : /config
6380 readOnly : true
6481 volumes :
65- - name : config-volume
82+ - name : friendbot-secret
6683 secret :
67- secretName : {{ template "common.fullname" . }}-vol
84+ secretName : {{ include "friendbot.secretName" . }}
85+ - name : friendbot-conf
86+ configMap :
87+ name : {{ template "common.fullname" . }}-config
0 commit comments