From baf128d856f08116f804fb41a994b79895c616fc Mon Sep 17 00:00:00 2001 From: Michael McLeroy Date: Tue, 13 Sep 2022 15:55:16 -0400 Subject: [PATCH] feat(helm): added imagepullsecrets --- charts/podinfo/README.md | 1 + charts/podinfo/templates/serviceaccount.yaml | 4 ++++ charts/podinfo/values-prod.yaml | 2 ++ charts/podinfo/values.yaml | 2 ++ 4 files changed, 9 insertions(+) diff --git a/charts/podinfo/README.md b/charts/podinfo/README.md index cbfe755..46e217b 100644 --- a/charts/podinfo/README.md +++ b/charts/podinfo/README.md @@ -70,6 +70,7 @@ Parameter | Default | Description `hpa.requests` | `None` | Target HTTP requests per second per pod `serviceAccount.enabled` | `false` | Whether a service account should be created `serviceAccount.name` | `None` | The name of the service account to use, if not set and create is true, a name is generated using the fullname template +`serviceAccount.imagePullSecrets` | `[]` | List of image pull secrets if pulling from private registries. `securityContext` | `{}` | The security context to be set on the podinfo container `linkerd.profile.enabled` | `false` | Create Linkerd service profile `serviceMonitor.enabled` | `false` | Whether a Prometheus Operator service monitor should be created diff --git a/charts/podinfo/templates/serviceaccount.yaml b/charts/podinfo/templates/serviceaccount.yaml index 7a55ea8..72ff524 100644 --- a/charts/podinfo/templates/serviceaccount.yaml +++ b/charts/podinfo/templates/serviceaccount.yaml @@ -5,4 +5,8 @@ metadata: name: {{ template "podinfo.serviceAccountName" . }} labels: {{- include "podinfo.labels" . | nindent 4 }} +{{- with .Values.serviceAccount.imagePullSecrets }} +imagePullSecrets: + {{- toYaml . | nindent 2 }} {{- end -}} +{{- end -}} \ No newline at end of file diff --git a/charts/podinfo/values-prod.yaml b/charts/podinfo/values-prod.yaml index 90d3ed9..5992bde 100644 --- a/charts/podinfo/values-prod.yaml +++ b/charts/podinfo/values-prod.yaml @@ -91,6 +91,8 @@ serviceAccount: # The name of the service account to use. # If not set and create is true, a name is generated using the fullname template name: + # List of image pull secrets if pulling from private registries + imagePullSecrets: [] # set container security context securityContext: {} diff --git a/charts/podinfo/values.yaml b/charts/podinfo/values.yaml index 0bbd68b..787ab0c 100644 --- a/charts/podinfo/values.yaml +++ b/charts/podinfo/values.yaml @@ -95,6 +95,8 @@ serviceAccount: # The name of the service account to use. # If not set and create is true, a name is generated using the fullname template name: + # List of image pull secrets if pulling from private registries + imagePullSecrets: [] # set container security context securityContext: {}