fix ui.serviceNodePort schema (#537)
UI service nodePort defaults to null, but is set as an integer
This commit is contained in:
parent
3afcb463f8
commit
af25981752
2 changed files with 27 additions and 1 deletions
|
@ -300,3 +300,26 @@ load _helpers
|
|||
yq -r '.spec.selector["vault-active"]' | tee /dev/stderr)
|
||||
[ "${actual}" = 'true' ]
|
||||
}
|
||||
|
||||
@test "ui/Service: default is no nodePort" {
|
||||
cd `chart_dir`
|
||||
|
||||
local actual=$(helm template \
|
||||
--show-only templates/ui-service.yaml \
|
||||
--set 'ui.enabled=true' \
|
||||
. | tee /dev/stderr |
|
||||
yq -r '.spec.ports[0].nodePort' | tee /dev/stderr)
|
||||
[ "${actual}" = "null" ]
|
||||
}
|
||||
|
||||
@test "ui/Service: can set nodePort" {
|
||||
cd `chart_dir`
|
||||
|
||||
local actual=$(helm template \
|
||||
--show-only templates/ui-service.yaml \
|
||||
--set 'ui.enabled=true' \
|
||||
--set 'ui.serviceNodePort=123' \
|
||||
. | tee /dev/stderr |
|
||||
yq -r '.spec.ports[0].nodePort' | tee /dev/stderr)
|
||||
[ "${actual}" = "123" ]
|
||||
}
|
||||
|
|
|
@ -775,7 +775,10 @@
|
|||
"type": "boolean"
|
||||
},
|
||||
"serviceNodePort": {
|
||||
"type": "null"
|
||||
"type": [
|
||||
"null",
|
||||
"integer"
|
||||
]
|
||||
},
|
||||
"serviceType": {
|
||||
"type": "string"
|
||||
|
|
Loading…
Reference in a new issue