Add missing imagePullSecrets overrides for monitor app

Clean up the Add-imagePullSecrets.patch to remove redundant
imagePullSecrets.

Update manifest with correct imagePullSecrets overrides in
order to allow stx-monitor to pull images from local docker
registry on each node.

stx-monitor app applied successfully and verified that each
running pod has the following in its spec:
imagePullSecrets:
  - name: default-registry-key

Change-Id: I330004bd44b255a46e2d1fb29ada63dbcd46e881
Closes-Bug: 1860132
Signed-off-by: Angie Wang <angie.wang@windriver.com>
This commit is contained in:
Angie Wang 2020-01-23 17:23:33 -05:00
parent 757fc67c25
commit 56e309f772
2 changed files with 27 additions and 58 deletions

View File

@ -1,65 +1,16 @@
From 440cae178989bf161276be0099691e9b7e5d211f Mon Sep 17 00:00:00 2001
From: John Kung <john.kung@windriver.com>
Date: Tue, 5 Nov 2019 07:42:36 -0500
From 1f506385234b0f1ef088afdecb6002b3e9c84305 Mon Sep 17 00:00:00 2001
From: Angie Wang <angie.wang@windriver.com>
Date: Thu, 23 Jan 2020 14:37:40 -0500
Subject: [PATCH 1/1] Add imagePullSecrets
Add imagePullSecrets for the missing chart.
---
stable/elasticsearch-curator/templates/serviceaccount.yaml | 2 ++
stable/filebeat/templates/serviceaccount.yaml | 2 ++
stable/kibana/templates/serviceaccount.yaml | 2 ++
stable/kube-state-metrics/values.yaml | 2 +-
stable/metricbeat/templates/serviceaccount.yaml | 2 ++
5 files changed, 9 insertions(+), 1 deletion(-)
stable/metricbeat/templates/serviceaccount.yaml | 2 ++
stable/metricbeat/values.yaml | 2 ++
2 files changed, 4 insertions(+)
diff --git a/stable/elasticsearch-curator/templates/serviceaccount.yaml b/stable/elasticsearch-curator/templates/serviceaccount.yaml
index ad9c5c9..a64b426 100644
--- a/stable/elasticsearch-curator/templates/serviceaccount.yaml
+++ b/stable/elasticsearch-curator/templates/serviceaccount.yaml
@@ -8,5 +8,7 @@ metadata:
chart: {{ template "elasticsearch-curator.chart" . }}
release: "{{ .Release.Name }}"
heritage: "{{ .Release.Service }}"
+imagePullSecrets:
+ - name: default-registry-key
{{- end }}
diff --git a/stable/filebeat/templates/serviceaccount.yaml b/stable/filebeat/templates/serviceaccount.yaml
index 7de907b..19a4d34 100644
--- a/stable/filebeat/templates/serviceaccount.yaml
+++ b/stable/filebeat/templates/serviceaccount.yaml
@@ -8,4 +8,6 @@ metadata:
chart: {{ template "filebeat.chart" . }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
+imagePullSecrets:
+ - name: default-registry-key
{{- end -}}
diff --git a/stable/kibana/templates/serviceaccount.yaml b/stable/kibana/templates/serviceaccount.yaml
index 948390a..edc0122 100644
--- a/stable/kibana/templates/serviceaccount.yaml
+++ b/stable/kibana/templates/serviceaccount.yaml
@@ -8,4 +8,6 @@ metadata:
chart: {{ .Chart.Name }}-{{ .Chart.Version }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
+imagePullSecrets:
+ - name: default-registry-key
{{- end -}}
diff --git a/stable/kube-state-metrics/values.yaml b/stable/kube-state-metrics/values.yaml
index 2bf5b30..bab7a30 100644
--- a/stable/kube-state-metrics/values.yaml
+++ b/stable/kube-state-metrics/values.yaml
@@ -31,7 +31,7 @@ serviceAccount:
name:
# 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: []
+ imagePullSecrets: [{"name": "default-registry-key"}]
prometheus:
monitor:
diff --git a/stable/metricbeat/templates/serviceaccount.yaml b/stable/metricbeat/templates/serviceaccount.yaml
index c53fc5a..a4c7659 100644
index c53fc5a..c2378ec 100644
--- a/stable/metricbeat/templates/serviceaccount.yaml
+++ b/stable/metricbeat/templates/serviceaccount.yaml
@@ -8,4 +8,6 @@ metadata:
@ -67,8 +18,18 @@ index c53fc5a..a4c7659 100644
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
+imagePullSecrets:
+ - name: default-registry-key
+{{ toYaml .Values.serviceAccount.imagePullSecrets | indent 2 }}
{{- end -}}
diff --git a/stable/metricbeat/values.yaml b/stable/metricbeat/values.yaml
index b59c428..a784e7a 100644
--- a/stable/metricbeat/values.yaml
+++ b/stable/metricbeat/values.yaml
@@ -167,3 +167,5 @@ serviceAccount:
# The name of the ServiceAccount to use.
# If not set and create is true, a name is generated using the fullname template
name:
+ # Reference to one or more secrets to be used when pulling images
+ imagePullSecrets: []
--
1.8.3.1

View File

@ -281,6 +281,8 @@ data:
release: mon-elasticsearch-curator
type: pod
values:
image:
pullSecret: default-registry-key
rbac:
enabled: True
env:
@ -414,6 +416,7 @@ data:
image:
repository: docker.elastic.co/beats/filebeat-oss
tag: 7.4.0
pullSecrets: ['default-registry-key']
monitoring:
enabled: true
config:
@ -494,6 +497,8 @@ data:
image:
repository: docker.elastic.co/beats/metricbeat-oss
tag: 7.4.0
serviceAccount:
imagePullSecrets: [{"name": "default-registry-key"}]
daemonset:
config:
output.file:
@ -612,6 +617,8 @@ data:
initialDelaySeconds: 60
periodSeconds: 30
timeoutSeconds: 30
serviceAccount:
imagePullSecrets: [{"name": "default-registry-key"}]
source:
type: tar
location: http://172.17.0.1:8080/helm_charts/starlingx/kube-state-metrics-2.4.1.tgz
@ -650,6 +657,7 @@ data:
image:
repository: docker.elastic.co/kibana/kibana-oss
tag: 7.4.0
pullSecrets: [{'name': 'default-registry-key'}]
ingress:
enabled: true
annotations: