Update teleport
This commit is contained in:
@@ -1041,4 +1041,102 @@ tests:
|
||||
- matchSnapshot: {}
|
||||
- matchRegex:
|
||||
path: spec.template.spec.initContainers[0].command[3]
|
||||
pattern: ".svc.test.com$"
|
||||
pattern: ".svc.test.com$"
|
||||
|
||||
- it: sets readinessProbe values on Deployment Pods
|
||||
template: proxy/deployment.yaml
|
||||
set:
|
||||
clusterName: helm-lint
|
||||
readinessProbe:
|
||||
initialDelaySeconds: 9
|
||||
periodSeconds: 10
|
||||
failureThreshold: 11
|
||||
successThreshold: 12
|
||||
proxy:
|
||||
# we test an auth-specific override
|
||||
readinessProbe:
|
||||
initialDelaySeconds: 13
|
||||
asserts:
|
||||
- equal:
|
||||
path: spec.template.spec.containers[0].readinessProbe.periodSeconds
|
||||
value: 10
|
||||
- equal:
|
||||
path: spec.template.spec.containers[0].readinessProbe.failureThreshold
|
||||
value: 11
|
||||
- equal:
|
||||
path: spec.template.spec.containers[0].readinessProbe.successThreshold
|
||||
value: 12
|
||||
- equal:
|
||||
path: spec.template.spec.containers[0].readinessProbe.initialDelaySeconds
|
||||
value: 13
|
||||
|
||||
- it: sets topology spread constraints by default
|
||||
template: proxy/deployment.yaml
|
||||
set:
|
||||
clusterName: helm-lint
|
||||
asserts:
|
||||
- equal:
|
||||
path: spec.template.spec.topologySpreadConstraints
|
||||
value:
|
||||
- maxSkew: 1
|
||||
topologyKey: kubernetes.io/hostname
|
||||
whenUnsatisfiable: ScheduleAnyway
|
||||
labelSelector:
|
||||
matchLabels:
|
||||
app.kubernetes.io/component: proxy
|
||||
app.kubernetes.io/instance: RELEASE-NAME
|
||||
app.kubernetes.io/name: teleport-cluster
|
||||
- maxSkew: 1
|
||||
topologyKey: topology.kubernetes.io/zone
|
||||
whenUnsatisfiable: ScheduleAnyway
|
||||
labelSelector:
|
||||
matchLabels:
|
||||
app.kubernetes.io/component: proxy
|
||||
app.kubernetes.io/instance: RELEASE-NAME
|
||||
app.kubernetes.io/name: teleport-cluster
|
||||
|
||||
- it: removes topology spread constraints when disabled
|
||||
template: proxy/deployment.yaml
|
||||
set:
|
||||
clusterName: helm-lint
|
||||
disableTopologySpreadConstraints: true
|
||||
asserts:
|
||||
- isEmpty:
|
||||
path: spec.template.spec.topologySpreadConstraints
|
||||
|
||||
- it: removes topology spread constraints when running on antique kubernetes
|
||||
template: proxy/deployment.yaml
|
||||
set:
|
||||
clusterName: helm-lint
|
||||
capabilities:
|
||||
majorVersion: 1
|
||||
minorVersion: 17
|
||||
asserts:
|
||||
- isEmpty:
|
||||
path: spec.template.spec.topologySpreadConstraints
|
||||
|
||||
- it: uses custom topology spread constraints when set
|
||||
template: proxy/deployment.yaml
|
||||
set:
|
||||
clusterName: helm-lint
|
||||
topologySpreadConstraints:
|
||||
- maxSkew: 2
|
||||
topologyKey: foobar
|
||||
whenUnsatisfiable: ScheduleAnyway
|
||||
labelSelector:
|
||||
matchLabels:
|
||||
app: baz
|
||||
# helm unit-test has a bug where capabilities are not reset between tests, we must set back to 1.18 after the 1.17 test.
|
||||
capabilities:
|
||||
majorVersion: 1
|
||||
minorVersion: 18
|
||||
asserts:
|
||||
- equal:
|
||||
path: spec.template.spec.topologySpreadConstraints
|
||||
value:
|
||||
- maxSkew: 2
|
||||
topologyKey: foobar
|
||||
whenUnsatisfiable: ScheduleAnyway
|
||||
labelSelector:
|
||||
matchLabels:
|
||||
app: baz
|
||||
|
||||
Reference in New Issue
Block a user