Skip to content

Commit 9a4f96a

Browse files
author
Jonathan Yu
authored
feat: add network policy for workspaces (#149)
1 parent 6bca292 commit 9a4f96a

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

templates/networkpolicies.yaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
---
2+
apiVersion: networking.k8s.io/v1
3+
kind: NetworkPolicy
4+
metadata:
5+
name: ingress-deny-all
6+
namespace: {{ .Release.Namespace }}
7+
spec:
8+
# Deny all ingress traffic for workspace pods. The coder agent initiates
9+
# all network traffic (TURN-over-HTTPS or STUN)
10+
podSelector:
11+
matchLabels:
12+
com.coder.resource: "true"
13+
policyTypes:
14+
- Ingress
15+
ingress: []

0 commit comments

Comments
 (0)