From ef58054dff356334cdbfd96f04dc7c149768c76d Mon Sep 17 00:00:00 2001 From: "Sphicas, Phil (ps3910)" Date: Tue, 15 Oct 2019 13:55:37 -0700 Subject: [PATCH] helm-toolkit: netpol requires DNS-1123 names Ensures that network policy names do not have underscores. Change-Id: I09faa30b7402daa6f8ff8591d17040e2f94d1c20 --- helm-toolkit/templates/manifests/_network_policy.tpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/helm-toolkit/templates/manifests/_network_policy.tpl b/helm-toolkit/templates/manifests/_network_policy.tpl index 8be73f00d..645676586 100644 --- a/helm-toolkit/templates/manifests/_network_policy.tpl +++ b/helm-toolkit/templates/manifests/_network_policy.tpl @@ -86,7 +86,7 @@ return: | apiVersion: networking.k8s.io/v1 kind: NetworkPolicy metadata: - name: {{ $label }}-netpol + name: {{ $label | replace "_" "-" }}-netpol namespace: {{ $envAll.Release.Namespace }} spec: {{- if hasKey (index $envAll.Values "network_policy") $label }}