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

optional ingressClassName

parent f747a9b7
No related branches found
No related tags found
No related merge requests found
......@@ -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
......@@ -70,3 +64,14 @@ tests:
path: spec.ingressClassName
- isNull:
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