From d7723fb0f47dd8acae6a38e4efead704c47fd27d Mon Sep 17 00:00:00 2001 From: Marcos Estevez Date: Mon, 7 Jan 2019 16:11:57 +0100 Subject: [PATCH] [chart] Adding imagePullSecrets to Service Account Signed-off-by: Marcos Estevez --- deploy/chart/Chart.yaml | 2 +- deploy/chart/README.md | 1 + deploy/chart/templates/serviceaccount.yaml | 3 +++ deploy/chart/values.yaml | 7 +++++++ 4 files changed, 12 insertions(+), 1 deletion(-) diff --git a/deploy/chart/Chart.yaml b/deploy/chart/Chart.yaml index 18881a605..512d8ad39 100644 --- a/deploy/chart/Chart.yaml +++ b/deploy/chart/Chart.yaml @@ -1,5 +1,5 @@ name: cert-manager -version: v0.6.0-dev.6 +version: v0.6.0-dev.7 appVersion: v0.6.0-dev.4 description: A Helm chart for cert-manager home: https://github.com/jetstack/cert-manager diff --git a/deploy/chart/README.md b/deploy/chart/README.md index 3a5cf0c14..4cc441ea8 100644 --- a/deploy/chart/README.md +++ b/deploy/chart/README.md @@ -64,6 +64,7 @@ The following table lists the configurable parameters of the cert-manager chart | Parameter | Description | Default | | --------- | ----------- | ------- | +| `global.imagePullSecrets` | Reference to one or more secrets to be used when pulling images | `[]` | | `image.repository` | Image repository | `quay.io/jetstack/cert-manager-controller` | | `image.tag` | Image tag | `canary` | | `image.pullPolicy` | Image pull policy | `Always` | diff --git a/deploy/chart/templates/serviceaccount.yaml b/deploy/chart/templates/serviceaccount.yaml index 39271bbcb..ef456aab2 100644 --- a/deploy/chart/templates/serviceaccount.yaml +++ b/deploy/chart/templates/serviceaccount.yaml @@ -1,6 +1,9 @@ {{- if .Values.serviceAccount.create -}} apiVersion: v1 kind: ServiceAccount +{{- if .Values.global.imagePullSecrets }} +imagePullSecrets: {{ toYaml .Values.global.imagePullSecrets | nindent 2 }} +{{- end }} metadata: name: {{ template "cert-manager.serviceAccountName" . }} namespace: {{ .Release.Namespace | quote }} diff --git a/deploy/chart/values.yaml b/deploy/chart/values.yaml index 3b679099c..b2c464eea 100644 --- a/deploy/chart/values.yaml +++ b/deploy/chart/values.yaml @@ -1,6 +1,13 @@ # Default values for cert-manager. # This is a YAML-formatted file. # Declare variables to be passed into your templates. +global: + ## Reference to one or more secrets to be used when pulling images + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ + ## + imagePullSecrets: [] + # - name: "image-pull-secret" + replicaCount: 1 strategy: {}