Files
netbird-kubernetes-operator/helm/kubernetes-operator/templates/nbpolicies.yaml
T
2025-03-06 09:57:45 +01:00

28 lines
665 B
YAML

{{- range $k, $v := $.Values.ingress.policies }}
---
apiVersion: netbird.io/v1
kind: NBPolicy
metadata:
finalizers:
- netbird.io/cleanup
labels:
app.kubernetes.io/component: operator
{{- include "kubernetes-operator.labels" $ | nindent 4 }}
name: {{ $k }}
spec:
name: {{ $v.name }}
sourceGroups:
{{ toYaml $v.sourceGroups | nindent 4}}
{{- if $v.description }}
description: {{ $v.description }}
{{- end }}
{{- if $v.protocols }}
protocols: {{ $v.protocols }}
{{- end }}
{{- if $v.ports }}
ports: {{ $v.ports }}
{{- end }}
{{- if hasKey $v "bidirectional" }}
bidirectional: {{ $v.bidirectional }}
{{- end }}
{{- end }}