-
Notifications
You must be signed in to change notification settings - Fork 64
MultiNetwork Policy should be namespaced #153
Copy link
Copy link
Open
Description
According to the following:
oc api-resources --api-group='k8s.cni.cncf.io'
NAME SHORTNAMES APIVERSION NAMESPACED KIND
ipamclaims k8s.cni.cncf.io/v1alpha1 true IPAMClaim
multi-networkpolicies multi-policy k8s.cni.cncf.io/v1beta1 true MultiNetworkPolicy
network-attachment-definitions net-attach-def k8s.cni.cncf.io/v1 true NetworkAttachmentDefinition
The https://github.com/openshift-kni/telco-reference/blob/main/telco-core/configuration/reference-crs-kube-compare/required/networking/multinetworkpolicy/multiNetworkPolicyAllowPortProtocol.yaml#L5 should include a wildcard for a namespace:
apiVersion: k8s.cni.cncf.io/v1beta1
kind: MultiNetworkPolicy
metadata:
name: allow-port-and-protocol
{{- if .metadata }}
namespace: {{ .metadata.namespace }}
{{- end }}
The documentation suggests the namespace to be present for its CLI version: https://docs.redhat.com/en/documentation/openshift_container_platform/4.18/html/networking/multiple-networks#nw-networkpolicy-create-cli_configuring-multi-network-policy
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels