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

Merge pull request 'optional-ingress-class-name' (#77) from optional-ingress-class-name into master

parents 50aa1a62 80e9c18e
Branches
Tags
Loading
......@@ -36,8 +36,8 @@ metadata:
name: {{ include "app.name" . }}
namespace: {{ include "app.namespace" . }}
spec:
{{- if ne (.Values).cluster_env "dataport"}}
ingressClassName: nginx
{{- if and (.Values.ingress).className (ne (.Values).cluster_env "dataport") }}
ingressClassName: {{ .Values.ingress.className }}
{{- end }}
rules:
- http:
......
......@@ -26,25 +26,19 @@ suite: test ingress options
templates:
- templates/ingress.yaml
tests:
- it: should create afm ingress tls/ingressClass
- it: should create afm ingress tls
release:
name: afm-adapter
asserts:
- equal:
path: spec.ingressClassName
value: nginx
- equal:
path: spec.tls[0].secretName
value: helm-afm-adapter-tls
- it: should create afm ingress tls/ingressClass
- it: should create afm ingress tls
release:
name: fs-adapter
set:
image.name: formsolutions-adapter
asserts:
- equal:
path: spec.ingressClassName
value: nginx
- equal:
path: spec.tls[0].secretName
value: helm-fs-adapter-tls
......@@ -69,4 +63,15 @@ tests:
- isNull:
path: spec.ingressClassName
- isNull:
path: spec.tls[0].secretName
\ No newline at end of file
path: spec.tls[0].secretName
- it: should not set ingressClassName
asserts:
- isNull:
path: spec.ingressClassName
- it: should set ingressClassName
set:
ingress.className: nginx
asserts:
- equal:
path: spec.ingressClassName
value: nginx
\ 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