From 422a6845c7e39c01c987eaf02f6a9dbbae836698 Mon Sep 17 00:00:00 2001 From: bravof Date: Tue, 7 Jul 2020 15:59:54 -0400 Subject: [PATCH 1/2] fix(initcontainers): getting rid of cleanup container and changing it by a readinessprobe --- .../eechart/charts/snmpexporter/templates/deployment.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/deployment.yaml b/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/deployment.yaml index 19ef0d9c..a7b0bdf4 100644 --- a/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/deployment.yaml +++ b/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/deployment.yaml @@ -45,6 +45,12 @@ spec: mountPath: /etc/snmp_exporter - name: internal-comm mountPath: /etc/internalcomm + readinessProbe: + exec: + command: + - /bin/sh + - -c + - if [ -f "/etc/snmp_exporter/generator.yml" ]; then touch /internalcomm/ok.init; fi livenessProbe: exec: command: -- GitLab From be9a2a988bf17b58bed9823844554fe96c21d350 Mon Sep 17 00:00:00 2001 From: bravof Date: Tue, 7 Jul 2020 16:02:34 -0400 Subject: [PATCH 2/2] fix(initcontainers): getting rid of cleanup container and changing it by a readinessprobe --- .../charts/snmpexporter/templates/deployment.yaml | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/deployment.yaml b/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/deployment.yaml index a7b0bdf4..8b690bbb 100644 --- a/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/deployment.yaml +++ b/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/deployment.yaml @@ -17,14 +17,6 @@ spec: securityContext: runAsUser: 0 initContainers: - - name: cleanup - image: busybox:1.28 - command: ['sh', '-c', 'if [ -f "/etc/snmp_exporter/generator.yml" ]; then touch /internalcomm/ok.init; fi'] - volumeMounts: - - name: config-volume - mountPath: /etc/snmp_exporter - - name: internal-comm - mountPath: /internalcomm - name: init-config image: busybox:1.28 command: ['sh', '-c', 'if [ ! -f "/etc/snmp_exporter/snmp.yml" ]; then cp /etc/snmp_exporter_init/snmp.yml /etc/snmp_exporter; fi'] @@ -45,7 +37,7 @@ spec: mountPath: /etc/snmp_exporter - name: internal-comm mountPath: /etc/internalcomm - readinessProbe: + startupProbe: exec: command: - /bin/sh -- GitLab