Skip to content

Commit bb4dbaa

Browse files
feat(helm): add configurable initContainers (startup containers) to Intel deployment (#202)
Fixes: #201 - This PR adds support for configurable “startup containers” by allowing users to define Kubernetes initContainers in the Intel Helm chart.
1 parent 9a6874d commit bb4dbaa

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

charts/intel/templates/deployment.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,12 @@ spec:
2727
- name: {{ include "codetogether.fullname" . }}-pull-secret
2828
{{- end }}
2929
serviceAccountName: {{ include "codetogether.serviceAccountName" . }}
30+
31+
{{- with .Values.initContainers }}
32+
initContainers:
33+
{{- toYaml . | nindent 8 }}
34+
{{- end }}
35+
3036
containers:
3137
- name: {{ .Chart.Name }}
3238
securityContext:

charts/intel/values.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,19 @@ serviceAccount:
133133

134134
podAnnotations: {}
135135

136+
# Optional: add initContainers (startup containers) to the pod spec.
137+
# Useful to wait for Cassandra or run startup checks before Intel starts.
138+
initContainers: []
139+
# Example:
140+
# initContainers:
141+
# - name: wait-for-cassandra
142+
# image: busybox:1.36
143+
# command: ["sh", "-c"]
144+
# args:
145+
# - >
146+
# until nc -z codetogether-cassandra.default.svc.cluster.local 9042;
147+
# do echo "Waiting for Cassandra..."; sleep 2; done
148+
136149
securityContext: {} #defaults
137150
# capabilities:
138151
# drop:

0 commit comments

Comments
 (0)