From 2131b4c59b10e556549e7f7c07856d1be4fb37ce Mon Sep 17 00:00:00 2001 From: "Waylon S. Walker" Date: Sun, 23 Feb 2025 20:50:55 -0600 Subject: [PATCH] fix syntax error --- helm-chart/templates/networkpolicy.yaml | 31 +++++++++++++------------ 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/helm-chart/templates/networkpolicy.yaml b/helm-chart/templates/networkpolicy.yaml index 1e00975..2c219c8 100644 --- a/helm-chart/templates/networkpolicy.yaml +++ b/helm-chart/templates/networkpolicy.yaml @@ -1,14 +1,14 @@ apiVersion: networking.k8s.io/v1 kind: NetworkPolicy metadata: - name: {? {.Values.name: ''} : ''} - namespace: {? {.Values.namespace | default .Values.name: ''} : ''} + name: {{ .Values.name }} + namespace: {{ .Values.namespace | default .Values.name }} labels: - service: {? {.Values.name: ''} : ''} + service: {{ .Values.name }} spec: podSelector: matchLabels: - service: {? {.Values.name: ''} : ''} + service: {{ .Values.name }} policyTypes: - Ingress - Egress @@ -19,14 +19,15 @@ spec: name: ingress-nginx ports: - protocol: TCP - port: {? {.Values.port: ''} : ''} - egress: {} - # TODO, optionally add egress restriction. - # - to: - # - namespaceSelector: {} - # podSelector: {} - # ports: - # - protocol: TCP - # port: 53 - # - protocol: UDP - # port: 53 + port: {{ .Values.port }} + egress: + - {} + # TODO, optionally add egress restriction. + # - to: + # - namespaceSelector: {} + # podSelector: {} + # ports: + # - protocol: TCP + # port: 53 + # - protocol: UDP + # port: 53