Skip to content

Commit 66cf5ce

Browse files
committed
chore(charts): add diagnostic mode
1 parent 3b084cb commit 66cf5ce

2 files changed

Lines changed: 21 additions & 0 deletions

File tree

charts/passport/templates/passport-deployment.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,11 @@ spec:
4141
- name: drycc-passport
4242
image: {{.Values.imageRegistry}}/{{.Values.imageOrg}}/passport:{{.Values.imageTag}}
4343
imagePullPolicy: {{.Values.imagePullPolicy}}
44+
{{- if .Values.diagnosticMode.enabled }}
45+
command: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.command "context" $) | nindent 10 }}
46+
args: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.args "context" $) | nindent 10 }}
47+
{{- end }}
48+
{{- if not .Values.diagnosticMode.enabled }}
4449
livenessProbe:
4550
httpGet:
4651
path: /healthz
@@ -54,6 +59,7 @@ spec:
5459
initialDelaySeconds: 30
5560
timeoutSeconds: 10
5661
periodSeconds: 5
62+
{{- end }}
5763
ports:
5864
- containerPort: 8000
5965
name: http

charts/passport/values.yaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,21 @@ imagePullPolicy: "Always"
33
imageTag: "canary"
44
imageRegistry: "registry.drycc.cc"
55

6+
## Enable diagnostic mode
7+
##
8+
diagnosticMode:
9+
## @param diagnosticMode.enabled Enable diagnostic mode (all probes will be disabled and the command will be overridden)
10+
##
11+
enabled: false
12+
## @param diagnosticMode.command Command to override all containers
13+
##
14+
command:
15+
- sleep
16+
## @param diagnosticMode.args Args to override all containers
17+
##
18+
args:
19+
- infinity
20+
621
nodeAffinityPreset:
722
key: "drycc.cc/node"
823
type: "soft"

0 commit comments

Comments
 (0)