more fixes for the netpolicy schema.

This commit is contained in:
Erik Brakkee 2025-01-03 00:31:03 +01:00
parent b8dfaa55a4
commit e576e00456

View File

@ -15,11 +15,11 @@
namespaceSelector:
matchLabels:
kubernetes.io/metadata.name: {{ .Application.Namespace.Name }}
{{- if .Ports }}
ports:
{{- template "ports" .Ports }}
{{- end }}
{{- end }}
{{- if .Ports }}
ports:
{{- template "ports" .Ports }}
{{- end }}
{{- end }}
{{- end }}
{{- define "networks" }}
{{- range .Networks }}
@ -31,11 +31,11 @@
{{- range $except := .Network.Except }}
- {{ $except }}
{{- end }}
{{- if .Ports }}
ports:
{{- template "ports" .Ports }}
{{- end }}
{{- end }}
{{- if .Ports }}
ports:
{{- template "ports" .Ports }}
{{- end }}
{{- end }}
{{- end }}
{{- if not .app.Namespace.Open }}