apiVersion: cilium.io/v2 kind: CiliumNetworkPolicy metadata: name: agentgateway-proxy namespace: agentgateway-system spec: endpointSelector: matchLabels: gateway.networking.k8s.io/gateway-name: agentgateway-proxy ingress: - fromEntities: - host toPorts: - ports: - port: "15020" protocol: TCP - port: "15021" protocol: TCP - fromEndpoints: - matchLabels: k8s:io.kubernetes.pod.namespace: victoriametrics app.kubernetes.io/name: vmagent app.kubernetes.io/instance: main toPorts: - ports: - port: "15020" protocol: TCP egress: - toEndpoints: - matchLabels: k8s:io.kubernetes.pod.namespace: agentgateway-system app.kubernetes.io/name: agentgateway app.kubernetes.io/instance: agentgateway toPorts: - ports: - port: "9978" protocol: TCP - toEndpoints: - matchLabels: k8s:io.kubernetes.pod.namespace: agentgateway-system app.kubernetes.io/name: model-catalog toPorts: - ports: - port: "8080" protocol: TCP - toEndpoints: - matchLabels: k8s:io.kubernetes.pod.namespace: kube-system k8s-app: kube-dns toPorts: - ports: - port: "53" protocol: UDP - port: "53" protocol: TCP - toEntities: - world toPorts: - serverNames: - api.novita.ai - oauth2.googleapis.com - "*.googleapis.com" ports: - port: "443" protocol: TCP --- apiVersion: cilium.io/v2 kind: CiliumClusterwideNetworkPolicy metadata: name: host-egress-agentgateway-proxy spec: nodeSelector: {} egress: - toEndpoints: - matchLabels: k8s:io.kubernetes.pod.namespace: agentgateway-system gateway.networking.k8s.io/gateway-name: agentgateway-proxy toPorts: - ports: - port: "15020" protocol: TCP - port: "15021" protocol: TCP