From 4c39f5d27a27c4516846ad3ecec4c4699448418e Mon Sep 17 00:00:00 2001 From: bravof Date: Wed, 15 Jul 2020 19:34:41 -0400 Subject: [PATCH 1/2] fix(name collission): fixing name collision between configmaps and pods in snmp example package Signed-off-by: bravof --- .../eechart/charts/snmpexporter/templates/base-config.yaml | 2 +- .../eechart/charts/snmpexporter/templates/deployment.yaml | 2 +- snmp_ee_vnf/helm-charts/eechart/templates/generator.yaml | 2 +- snmp_ee_vnf/helm-charts/eechart/templates/statefulset.yaml | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/base-config.yaml b/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/base-config.yaml index b3d45498..fcf2f181 100644 --- a/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/base-config.yaml +++ b/snmp_ee_vnf/helm-charts/eechart/charts/snmpexporter/templates/base-config.yaml @@ -2,7 +2,7 @@ apiVersion: v1 kind: ConfigMap metadata: - name: snmp-init-config + name: "snmp-init-config-{{ .Values.global.osm.vnf_id | lower}}" data: snmp.yml: |- # WARNING: This file was auto-generated using snmp_exporter generator, manual changes will be lost. 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 b4ffe301..e57e81c5 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 @@ -50,5 +50,5 @@ spec: path: "/var/lib/osm/snmp_exporter/{{ .Values.global.osm.vnf_id }}/" - name: init-config-volume configMap: - name: snmp-init-config + name: "snmp-init-config-{{ .Values.global.osm.vnf_id }}" diff --git a/snmp_ee_vnf/helm-charts/eechart/templates/generator.yaml b/snmp_ee_vnf/helm-charts/eechart/templates/generator.yaml index 98236e87..96f7e237 100644 --- a/snmp_ee_vnf/helm-charts/eechart/templates/generator.yaml +++ b/snmp_ee_vnf/helm-charts/eechart/templates/generator.yaml @@ -1,7 +1,7 @@ apiVersion: v1 kind: ConfigMap metadata: - name: vnf-snmp-generator + name: "vnf-snmp-generator-{{ .Values.global.osm.vnf_id | lower }}" data: generator.yml: |- {{ .Files.Get "snmp/generator.yml" | nindent 4}} \ No newline at end of file diff --git a/snmp_ee_vnf/helm-charts/eechart/templates/statefulset.yaml b/snmp_ee_vnf/helm-charts/eechart/templates/statefulset.yaml index d4bc2cc3..6df08496 100755 --- a/snmp_ee_vnf/helm-charts/eechart/templates/statefulset.yaml +++ b/snmp_ee_vnf/helm-charts/eechart/templates/statefulset.yaml @@ -49,13 +49,13 @@ spec: name: {{ include "eechart.fullname" . }} - name: snmp-config-volume hostPath: - path: "/var/lib/osm/snmp_exporter/{{ .Values.global.osm.vnf_id }}/" + path: "/var/lib/osm/snmp_exporter/{{ .Values.global.osm.vnf_id | lower }}/" - name: vnf-mibs configMap: name: vnf-snmp-mibs - name: vnf-generator configMap: - name: vnf-snmp-generator + name: "vnf-snmp-generator-{{ .Values.global.osm.vnf_id | lower}}" - name: osm-ee hostPath: path: /var/lib/osm/osm/osm_osm_packages/_data -- GitLab From cf4f2eda944c797e9a26f6518370d325f1ac1b7e Mon Sep 17 00:00:00 2001 From: bravof Date: Wed, 15 Jul 2020 19:44:52 -0400 Subject: [PATCH 2/2] fix(name collission): fixing name collision between configmaps and pods in snmp example package Signed-off-by: bravof --- .../eechart/charts/snmpexporter/templates/deployment.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 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 e57e81c5..5aef90fe 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 @@ -47,8 +47,8 @@ spec: volumes: - name: config-volume hostPath: - path: "/var/lib/osm/snmp_exporter/{{ .Values.global.osm.vnf_id }}/" + path: "/var/lib/osm/snmp_exporter/{{ .Values.global.osm.vnf_id | lower }}/" - name: init-config-volume configMap: - name: "snmp-init-config-{{ .Values.global.osm.vnf_id }}" + name: "snmp-init-config-{{ .Values.global.osm.vnf_id | lower }}" -- GitLab