Skip to content
Snippets Groups Projects
Commit 5d934c38 authored by OZG-Cloud Team's avatar OZG-Cloud Team
Browse files

ozg-6647 add monitoring network policy

parent f97c7106
No related branches found
No related tags found
No related merge requests found
......@@ -38,6 +38,13 @@ spec:
ingress:
- ports:
- port: 8080
- from:
- namespaceSelector:
matchLabels:
name: {{ (.Values.networkPolicy).monitoringNamespace | default "openshift-monitoring" }}
ports:
- protocol: TCP
port: 8081
egress:
- to:
- podSelector:
......
......@@ -70,6 +70,13 @@ tests:
ingress:
- ports:
- port: 8080
- from:
- namespaceSelector:
matchLabels:
name: openshift-monitoring
ports:
- protocol: TCP
port: 8081
egress:
- to:
- podSelector:
......@@ -92,6 +99,23 @@ tests:
- port: 5353
protocol: TCP
- it: should set monitoring namespace
set:
networkPolicy:
dnsServerNamespace: test-dns-namespace
monitoringNamespace: test-monitoring
asserts:
- contains:
path: spec.ingress
content:
from:
- namespaceSelector:
matchLabels:
name: test-monitoring
ports:
- protocol: TCP
port: 8081
- it: test network policy disabled
set:
networkPolicy:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment