Skip to content

Commit

Permalink
Bugfix: fix frontend netpol egress (#5464)
Browse files Browse the repository at this point in the history
* add istiod pod and dns queries to allowed egress

* enable netpols in kustomization

* remove frontend to api path in netpols
  • Loading branch information
lcampbell2 authored Jul 12, 2024
1 parent a72ae29 commit eb35a0f
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion k8s/apps/bases/api/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ resources:
- deployment.yaml
- service.yaml
- virtual-service.yaml
# - network-policy.yaml
- network-policy.yaml
- domain-cleanup-cronjob.yaml
6 changes: 0 additions & 6 deletions k8s/apps/bases/api/network-policy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,3 @@ spec:
namespaceSelector:
matchLabels:
kubernetes.io/metadata.name: istio-system
- podSelector:
matchLabels:
app: tracker-frontend
namespaceSelector:
matchLabels:
kubernetes.io/metadata.name: frontend
2 changes: 1 addition & 1 deletion k8s/apps/bases/frontend/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ resources:
- deployment.yaml
- service.yaml
- virtual-service.yaml
# - network-policy.yaml
- network-policy.yaml
- maintenance-deployment.yaml
- maintenance-service.yaml
10 changes: 8 additions & 2 deletions k8s/apps/bases/frontend/network-policy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,13 @@ spec:
- to:
- podSelector:
matchLabels:
app: tracker-api
app: istiod
namespaceSelector:
matchLabels:
kubernetes.io/metadata.name: api
kubernetes.io/metadata.name: istio-system
# DNS queries also need to be allowed
- ports:
- protocol: UDP
port: 53
- protocol: TCP
port: 53

0 comments on commit eb35a0f

Please sign in to comment.