Skip to content

Commit

Permalink
Merge pull request #508 from joejulian/image_pull_secrets_redpanda
Browse files Browse the repository at this point in the history
Add imagePullSecrets to redpanda chart
  • Loading branch information
RafalKorepta committed May 22, 2023
2 parents 648402a + a974e21 commit 3dda539
Show file tree
Hide file tree
Showing 18 changed files with 53 additions and 1 deletion.
2 changes: 1 addition & 1 deletion charts/redpanda/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ type: application
# The chart version and the app version are not the same and will not track
# together. The chart version is a semver representation of changes to this
# chart.
version: 4.0.21
version: 4.0.22

# The app version is the default version of Redpanda to install.
appVersion: v23.1.10
Expand Down
3 changes: 3 additions & 0 deletions charts/redpanda/templates/post-install-upgrade-job.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@ spec:
{{- end }}
restartPolicy: Never
securityContext: {{ include "pod-security-context" . | nindent 8 }}
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 8 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}-post-install
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/redpanda/templates/post-upgrade.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ spec:
restartPolicy: Never
securityContext: {{ include "pod-security-context" . | nindent 8 }}
serviceAccountName: {{ include "redpanda.serviceAccountName" . }}
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 8 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}-post-upgrade
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/redpanda/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@ spec:
terminationGracePeriodSeconds: {{ .Values.statefulset.terminationGracePeriodSeconds }}
securityContext: {{ include "pod-security-context" . | nindent 8 }}
serviceAccountName: {{ include "redpanda.serviceAccountName" . }}
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 8 }}
{{- end }}
initContainers:
{{- if and (hasKey $values.tuning "tune_aio_events") $values.tuning.tune_aio_events }}
- name: tuning
Expand Down
3 changes: 3 additions & 0 deletions charts/redpanda/templates/tests/test-api-status.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/redpanda/templates/tests/test-console.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/redpanda/templates/tests/test-kafka-sasl-status.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/redpanda/templates/tests/test-pandaproxy-status.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/redpanda/templates/tests/test-rack-awareness.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/redpanda/templates/tests/test-rpk-debug-bundle.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@ spec:
matchLabels:
statefulset.kubernetes.io/pod-name: {{ include "redpanda.fullname" . }}-0
topologyKey: kubernetes.io/hostname
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
initContainers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository}}:{{ template "redpanda.tag" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/redpanda/templates/tests/test-sasl-updated.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ spec:
securityContext:
runAsUser: 65535
runAsGroup: 65535
{{- with .Values.imagePullSecrets }}
imagePullSecrets: {{- toYaml . | nindent 4 }}
{{- end }}
containers:
- name: {{ template "redpanda.name" . }}
image: {{ .Values.image.repository }}:{{ template "redpanda.tag" . }}
Expand Down
4 changes: 4 additions & 0 deletions charts/redpanda/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@ image:
# If `image.tag` is 'latest', the default is `Always`.
pullPolicy: IfNotPresent

# -- Pull secrets may be used to provide credentials to image repositories
# See https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
imagePullSecrets: []

# -- Enterprise license key (optional).
# For details,
# see the [License documentation](https://docs.redpanda.com/docs/get-started/licenses/?platform=kubernetes#redpanda-enterprise-edition).
Expand Down

0 comments on commit 3dda539

Please sign in to comment.