Skip to content
Snippets Groups Projects
Commit bd4b3b6c authored by OZGCloud's avatar OZGCloud
Browse files

OZG-3880 network policy dynamic dns server config

parent fbe3df84
Branches
Tags
No related merge requests found
...@@ -160,7 +160,7 @@ pipeline { ...@@ -160,7 +160,7 @@ pipeline {
HELM_CHART_VERSION = generateHelmChartVersion() HELM_CHART_VERSION = generateHelmChartVersion()
dir('src/main/helm') { dir('src/main/helm') {
sh "helm lint -f ../../test/unit-values.yaml" sh "helm lint -f ../../test/linter-values.yaml"
sh "helm unittest --helm3 -f '../../test/helm/*.yaml' -v '../../test/unit-values.yaml' ." sh "helm unittest --helm3 -f '../../test/helm/*.yaml' -v '../../test/unit-values.yaml' ."
......
...@@ -29,14 +29,23 @@ templates: ...@@ -29,14 +29,23 @@ templates:
- templates/network_policy.yaml - templates/network_policy.yaml
tests: tests:
- it: should match apiVersion - it: should match apiVersion
set:
networkPolicy:
dnsServerNamespace: test-namespace-dns
asserts: asserts:
- isAPIVersion: - isAPIVersion:
of: networking.k8s.io/v1 of: networking.k8s.io/v1
- it: should match kind - it: should match kind
set:
networkPolicy:
dnsServerNamespace: test-namespace-dns
asserts: asserts:
- isKind: - isKind:
of: NetworkPolicy of: NetworkPolicy
- it: validate metadata - it: validate metadata
set:
networkPolicy:
dnsServerNamespace: test-namespace-dns
asserts: asserts:
- equal: - equal:
path: metadata path: metadata
...@@ -44,6 +53,9 @@ tests: ...@@ -44,6 +53,9 @@ tests:
name: network-policy-user-manager name: network-policy-user-manager
namespace: by-helm-test namespace: by-helm-test
- it: validate spec - it: validate spec
set:
networkPolicy:
dnsServerNamespace: test-namespace-dns
asserts: asserts:
- equal: - equal:
path: spec path: spec
...@@ -81,6 +93,7 @@ tests: ...@@ -81,6 +93,7 @@ tests:
- it: add ingress rule by values - it: add ingress rule by values
set: set:
networkPolicy: networkPolicy:
dnsServerNamespace: test-namespace-dns
additionalIngressConfig: additionalIngressConfig:
- podSelector: - podSelector:
matchLabels: matchLabels:
...@@ -99,6 +112,7 @@ tests: ...@@ -99,6 +112,7 @@ tests:
- it: test network policy disabled - it: test network policy disabled
set: set:
networkPolicy: networkPolicy:
dnsServerNamespace: test-namespace-dns
disabled: true disabled: true
asserts: asserts:
- hasDocuments: - hasDocuments:
...@@ -107,6 +121,7 @@ tests: ...@@ -107,6 +121,7 @@ tests:
- it: test network policy unset should be disabled - it: test network policy unset should be disabled
set: set:
networkPolicy: networkPolicy:
dnsServerNamespace: test-namespace-dns
disabled: false disabled: false
asserts: asserts:
- hasDocuments: - hasDocuments:
......
...@@ -37,4 +37,3 @@ sso: ...@@ -37,4 +37,3 @@ sso:
networkPolicy: networkPolicy:
ssoPublicIp: 51.89.117.53/32 ssoPublicIp: 51.89.117.53/32
dnsServerNamespace: test-namespace-dns
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment