about summary refs log tree commit diff
path: root/tools/monitoring
diff options
context:
space:
mode:
Diffstat (limited to 'tools/monitoring')
-rw-r--r--tools/monitoring/templates/network-policy.yaml27
1 files changed, 24 insertions, 3 deletions
diff --git a/tools/monitoring/templates/network-policy.yaml b/tools/monitoring/templates/network-policy.yaml
index c7696cb..9e8bd65 100644
--- a/tools/monitoring/templates/network-policy.yaml
+++ b/tools/monitoring/templates/network-policy.yaml
@@ -11,7 +11,28 @@ spec:
   ingress:
   - from:
     - podSelector: {}
-  egress:
-  - to:
-    - podSelector: {}
+  - from:
+    - namespaceSelector:
+        matchLabels:
+          name: monitoring
+---
+apiVersion: networking.k8s.io/v1
+kind: NetworkPolicy
+metadata:
+  name: allow-ingress-to-grafana
+  namespace: monitoring
+spec:
+  podSelector:
+    matchLabels:
+      app.kubernetes.io/name: grafana
+  ingress:
+  - from:
+    - namespaceSelector:
+        matchLabels:
+          name: kube-system
+    - podSelector:
+        matchLabels:
+          app: traefik
+  policyTypes:
+  - Ingress