|
| 1 | +suite: Test the Readiness Probe Configuration |
| 2 | +templates: |
| 3 | + - templates/daemonset.yaml |
| 4 | + - templates/deployment.yaml |
| 5 | +tests: |
| 6 | + - it: "[DaemonSet] Readiness Probe (agent > 12.18.0)" |
| 7 | + set: |
| 8 | + image: |
| 9 | + tag: 12.18.1 |
| 10 | + asserts: |
| 11 | + - equal: |
| 12 | + path: spec.template.spec.containers[0].readinessProbe |
| 13 | + value: |
| 14 | + httpGet: |
| 15 | + path: /healthz |
| 16 | + port: 24483 |
| 17 | + initialDelaySeconds: 90 |
| 18 | + periodSeconds: 3 |
| 19 | + template: templates/daemonset.yaml |
| 20 | + - it: "[DaemonSet] Readiness Probe (agent == 12.18.0)" |
| 21 | + set: |
| 22 | + image: |
| 23 | + tag: 12.18.0 |
| 24 | + asserts: |
| 25 | + - equal: |
| 26 | + path: spec.template.spec.containers[0].readinessProbe |
| 27 | + value: |
| 28 | + httpGet: |
| 29 | + path: /healthz |
| 30 | + port: 24483 |
| 31 | + initialDelaySeconds: 90 |
| 32 | + periodSeconds: 3 |
| 33 | + template: templates/daemonset.yaml |
| 34 | + - it: "[DaemonSet] Readiness Probe (agent < 12.18.0)" |
| 35 | + set: |
| 36 | + image: |
| 37 | + tag: 12.16.3 |
| 38 | + asserts: |
| 39 | + - equal: |
| 40 | + path: spec.template.spec.containers[0].readinessProbe |
| 41 | + value: |
| 42 | + exec: |
| 43 | + command: |
| 44 | + - test |
| 45 | + - -e |
| 46 | + - /opt/draios/logs/running |
| 47 | + initialDelaySeconds: 90 |
| 48 | + periodSeconds: 3 |
| 49 | + template: templates/daemonset.yaml |
| 50 | + - it: "[DelegatedAgentDeployment] Readiness Probe (agent > 12.18.0)" |
| 51 | + set: |
| 52 | + delegatedAgentDeployment: |
| 53 | + enabled: true |
| 54 | + image: |
| 55 | + tag: 12.18.1 |
| 56 | + asserts: |
| 57 | + - equal: |
| 58 | + path: spec.template.spec.containers[0].readinessProbe |
| 59 | + value: |
| 60 | + httpGet: |
| 61 | + path: /healthz |
| 62 | + port: 24483 |
| 63 | + initialDelaySeconds: 90 |
| 64 | + periodSeconds: 3 |
| 65 | + - it: "[DelegatedAgentDeployment] Readiness Probe (agent == 12.18.0)" |
| 66 | + set: |
| 67 | + delegatedAgentDeployment: |
| 68 | + enabled: true |
| 69 | + image: |
| 70 | + tag: 12.18.0 |
| 71 | + asserts: |
| 72 | + - equal: |
| 73 | + path: spec.template.spec.containers[0].readinessProbe |
| 74 | + value: |
| 75 | + httpGet: |
| 76 | + path: /healthz |
| 77 | + port: 24483 |
| 78 | + initialDelaySeconds: 90 |
| 79 | + periodSeconds: 3 |
| 80 | + - it: "[DelegatedAgentDeployment] Readiness Probe (agent < 12.18.0)" |
| 81 | + set: |
| 82 | + delegatedAgentDeployment: |
| 83 | + enabled: true |
| 84 | + image: |
| 85 | + tag: 12.16.3 |
| 86 | + asserts: |
| 87 | + - equal: |
| 88 | + path: spec.template.spec.containers[0].readinessProbe |
| 89 | + value: |
| 90 | + exec: |
| 91 | + command: |
| 92 | + - test |
| 93 | + - -e |
| 94 | + - /opt/draios/logs/running |
| 95 | + initialDelaySeconds: 90 |
| 96 | + periodSeconds: 3 |
| 97 | + - it: Test setting probe delays |
| 98 | + set: |
| 99 | + daemonset: |
| 100 | + probes: |
| 101 | + initialDelay: 5 |
| 102 | + periodDelay: 3 |
| 103 | + delegatedAgentDeployment: |
| 104 | + deployment: |
| 105 | + probes: |
| 106 | + initialDelay: 5 |
| 107 | + periodDelay: 3 |
| 108 | + enabled: true |
| 109 | + asserts: |
| 110 | + - equal: |
| 111 | + path: spec.template.spec.containers[0].readinessProbe.initialDelaySeconds |
| 112 | + value: 5 |
| 113 | + - equal: |
| 114 | + path: spec.template.spec.containers[0].readinessProbe.periodSeconds |
| 115 | + value: 3 |
0 commit comments