diff --git a/packages/kontinuous/tests/__snapshots__/app-sidecar.dev.yaml b/packages/kontinuous/tests/__snapshots__/app-sidecar.dev.yaml index 2cd59d303..aad4b94b9 100644 --- a/packages/kontinuous/tests/__snapshots__/app-sidecar.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/app-sidecar.dev.yaml @@ -164,14 +164,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -185,6 +183,22 @@ spec: requests: cpu: 41m memory: 131Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check - name: cronjob image: test/background-cronjob command: @@ -198,6 +212,32 @@ spec: requests: cpu: 41m memory: 131Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + readinessProbe: + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/app-simple-options.dev.yaml b/packages/kontinuous/tests/__snapshots__/app-simple-options.dev.yaml index 4f8a3e5df..40e6b4ad8 100644 --- a/packages/kontinuous/tests/__snapshots__/app-simple-options.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/app-simple-options.dev.yaml @@ -780,6 +780,8 @@ spec: - name: docs persistentVolumeClaim: claimName: docs + - name: readiness-check-volume + emptyDir: {} containers: - image: harbor.fabrique.social.gouv.fr/test-app-simple-options/app:sha-ffac537e6cbbf934b08745a378932722df287a53 name: app @@ -795,14 +797,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 124 httpGet: @@ -820,6 +820,21 @@ spec: volumeMounts: - name: docs mountPath: /mnt/docs + - name: readiness-check-volume + mountPath: /var/run/readiness-check + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/app-simple-options.prod.yaml b/packages/kontinuous/tests/__snapshots__/app-simple-options.prod.yaml index e3348f8bb..d9e7f988e 100644 --- a/packages/kontinuous/tests/__snapshots__/app-simple-options.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/app-simple-options.prod.yaml @@ -157,6 +157,8 @@ spec: - name: docs persistentVolumeClaim: claimName: docs + - name: readiness-check-volume + emptyDir: {} containers: - image: harbor.fabrique.social.gouv.fr/test-app-simple-options/app:prod name: app @@ -172,14 +174,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 124 httpGet: @@ -197,6 +197,21 @@ spec: volumeMounts: - name: docs mountPath: /mnt/docs + - name: readiness-check-volume + mountPath: /var/run/readiness-check + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/app-simple.dev.yaml b/packages/kontinuous/tests/__snapshots__/app-simple.dev.yaml index 83450a585..2e0e002f4 100644 --- a/packages/kontinuous/tests/__snapshots__/app-simple.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/app-simple.dev.yaml @@ -164,14 +164,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -185,6 +183,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/app-simple.prod.yaml b/packages/kontinuous/tests/__snapshots__/app-simple.prod.yaml index 5709cbcaf..0da8c2d57 100644 --- a/packages/kontinuous/tests/__snapshots__/app-simple.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/app-simple.prod.yaml @@ -163,14 +163,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -184,6 +182,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/chart-group.dev.yaml b/packages/kontinuous/tests/__snapshots__/chart-group.dev.yaml index 8c3e97404..d305d4288 100644 --- a/packages/kontinuous/tests/__snapshots__/chart-group.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/chart-group.dev.yaml @@ -87,14 +87,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -108,6 +106,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -195,14 +212,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -216,6 +231,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/chart-groups.dev.yaml b/packages/kontinuous/tests/__snapshots__/chart-groups.dev.yaml index 6f662dd2e..56f8478ca 100644 --- a/packages/kontinuous/tests/__snapshots__/chart-groups.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/chart-groups.dev.yaml @@ -87,14 +87,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -108,6 +106,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -195,14 +212,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -216,6 +231,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/chart-not-in-values.dev.yaml b/packages/kontinuous/tests/__snapshots__/chart-not-in-values.dev.yaml index 6e18806f9..ed3721c60 100644 --- a/packages/kontinuous/tests/__snapshots__/chart-not-in-values.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/chart-not-in-values.dev.yaml @@ -86,14 +86,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -107,6 +105,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/daemon.dev.yaml b/packages/kontinuous/tests/__snapshots__/daemon.dev.yaml index 3791add48..b125ba031 100644 --- a/packages/kontinuous/tests/__snapshots__/daemon.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/daemon.dev.yaml @@ -158,5 +158,31 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + readinessProbe: + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} " `; diff --git a/packages/kontinuous/tests/__snapshots__/extends-ovh.dev.yaml b/packages/kontinuous/tests/__snapshots__/extends-ovh.dev.yaml index 5a7cdabfd..12fb1c5a6 100644 --- a/packages/kontinuous/tests/__snapshots__/extends-ovh.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/extends-ovh.dev.yaml @@ -490,14 +490,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -511,6 +509,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/extends-ovh.prod.yaml b/packages/kontinuous/tests/__snapshots__/extends-ovh.prod.yaml index 1262df971..cb2853cd2 100644 --- a/packages/kontinuous/tests/__snapshots__/extends-ovh.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/extends-ovh.prod.yaml @@ -651,14 +651,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -672,6 +670,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/force-restart-optout.dev.yaml b/packages/kontinuous/tests/__snapshots__/force-restart-optout.dev.yaml index 918cee2c5..73458d1ed 100644 --- a/packages/kontinuous/tests/__snapshots__/force-restart-optout.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/force-restart-optout.dev.yaml @@ -146,16 +146,12 @@ spec: - -c - redis-cli ping readinessProbe: - failureThreshold: 15 - initialDelaySeconds: 1 - periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 exec: command: - - sh - - -c - - redis-cli ping + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 startupProbe: failureThreshold: 12 periodSeconds: 5 @@ -173,6 +169,25 @@ spec: memory: 128Mi securityContext: allowPrivilegeEscalation: false + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/hasura-no-ing.prod.yaml b/packages/kontinuous/tests/__snapshots__/hasura-no-ing.prod.yaml index 33c186d1e..5e497e140 100644 --- a/packages/kontinuous/tests/__snapshots__/hasura-no-ing.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/hasura-no-ing.prod.yaml @@ -144,14 +144,12 @@ spec: - containerPort: 8080 name: http readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 30 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 resources: limits: cpu: 1 @@ -167,6 +165,25 @@ spec: periodSeconds: 5 env: [] envFrom: [] + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/if-env.dev.yaml b/packages/kontinuous/tests/__snapshots__/if-env.dev.yaml index 9a65510a6..6bc8d3eb4 100644 --- a/packages/kontinuous/tests/__snapshots__/if-env.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/if-env.dev.yaml @@ -164,14 +164,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -185,6 +183,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/if-env.local.yaml b/packages/kontinuous/tests/__snapshots__/if-env.local.yaml index f09c9649e..ab7ea854b 100644 --- a/packages/kontinuous/tests/__snapshots__/if-env.local.yaml +++ b/packages/kontinuous/tests/__snapshots__/if-env.local.yaml @@ -161,14 +161,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -182,6 +180,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/ingress-external-domain.prod.yaml b/packages/kontinuous/tests/__snapshots__/ingress-external-domain.prod.yaml index c851453e0..2e783c700 100644 --- a/packages/kontinuous/tests/__snapshots__/ingress-external-domain.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/ingress-external-domain.prod.yaml @@ -190,14 +190,12 @@ spec: successThreshold: 1 timeoutSeconds: 10 readinessProbe: - failureThreshold: 15 - httpGet: - path: /api/health - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 livenessProbe: failureThreshold: 6 httpGet: @@ -213,6 +211,25 @@ spec: requests: cpu: 500m memory: 512Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/inline-values.dev.yaml b/packages/kontinuous/tests/__snapshots__/inline-values.dev.yaml index 8498218a3..4be2c805d 100644 --- a/packages/kontinuous/tests/__snapshots__/inline-values.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/inline-values.dev.yaml @@ -164,14 +164,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -185,6 +183,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/jobs-build-options.dev.yaml b/packages/kontinuous/tests/__snapshots__/jobs-build-options.dev.yaml index 7fc94155c..3b410026d 100644 --- a/packages/kontinuous/tests/__snapshots__/jobs-build-options.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/jobs-build-options.dev.yaml @@ -449,14 +449,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -477,6 +475,25 @@ spec: name: app-sealed-secret - configMapRef: name: app-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/jobs-build-stage.dev.yaml b/packages/kontinuous/tests/__snapshots__/jobs-build-stage.dev.yaml index 91146274a..78f622f36 100644 --- a/packages/kontinuous/tests/__snapshots__/jobs-build-stage.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/jobs-build-stage.dev.yaml @@ -1054,14 +1054,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1082,6 +1080,25 @@ spec: name: app-sealed-secret - configMapRef: name: app-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -1150,14 +1167,12 @@ spec: - containerPort: 8080 name: http readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 30 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 resources: limits: cpu: 1 @@ -1179,6 +1194,25 @@ spec: name: hasura-sealed-secret - configMapRef: name: hasura-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/jobs-build.dev.yaml b/packages/kontinuous/tests/__snapshots__/jobs-build.dev.yaml index 4c50f9aad..260115f1f 100644 --- a/packages/kontinuous/tests/__snapshots__/jobs-build.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/jobs-build.dev.yaml @@ -1052,14 +1052,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1080,6 +1078,25 @@ spec: name: app-sealed-secret - configMapRef: name: app-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -1148,14 +1165,12 @@ spec: - containerPort: 8080 name: http readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 30 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 resources: limits: cpu: 1 @@ -1177,6 +1192,25 @@ spec: name: hasura-sealed-secret - configMapRef: name: hasura-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/long-branch-host-patch.dev.yaml b/packages/kontinuous/tests/__snapshots__/long-branch-host-patch.dev.yaml index f453f2a9b..1891fbc9c 100644 --- a/packages/kontinuous/tests/__snapshots__/long-branch-host-patch.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/long-branch-host-patch.dev.yaml @@ -164,14 +164,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -185,6 +183,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/long-branch-host.dev.yaml b/packages/kontinuous/tests/__snapshots__/long-branch-host.dev.yaml index 848ea6f24..f5a36b679 100644 --- a/packages/kontinuous/tests/__snapshots__/long-branch-host.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/long-branch-host.dev.yaml @@ -164,14 +164,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -185,6 +183,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/maildev.dev.yaml b/packages/kontinuous/tests/__snapshots__/maildev.dev.yaml index 714983f9e..8e08e71f1 100644 --- a/packages/kontinuous/tests/__snapshots__/maildev.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/maildev.dev.yaml @@ -139,6 +139,8 @@ spec: volumeMounts: - name: data mountPath: /home/node/maildev-data + - name: readiness-check-volume + mountPath: /var/run/readiness-check ports: - name: http containerPort: 1080 @@ -151,9 +153,12 @@ spec: path: /healthz port: http readinessProbe: - httpGet: - path: /healthz - port: http + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 securityContext: runAsUser: 1000 runAsGroup: 1000 @@ -161,9 +166,24 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 volumes: - name: data emptyDir: {} + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/maildev.prod.yaml b/packages/kontinuous/tests/__snapshots__/maildev.prod.yaml index bb3183aea..5416cde63 100644 --- a/packages/kontinuous/tests/__snapshots__/maildev.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/maildev.prod.yaml @@ -138,6 +138,8 @@ spec: volumeMounts: - name: data mountPath: /home/node/maildev-data + - name: readiness-check-volume + mountPath: /var/run/readiness-check ports: - name: http containerPort: 1080 @@ -150,9 +152,12 @@ spec: path: /healthz port: http readinessProbe: - httpGet: - path: /healthz - port: http + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 securityContext: runAsUser: 1000 runAsGroup: 1000 @@ -160,9 +165,24 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 volumes: - name: data emptyDir: {} + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/meta-log.dev.yaml b/packages/kontinuous/tests/__snapshots__/meta-log.dev.yaml index 86b17b33e..1a767e5bd 100644 --- a/packages/kontinuous/tests/__snapshots__/meta-log.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/meta-log.dev.yaml @@ -422,14 +422,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -443,6 +441,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/metabase.prod.yaml b/packages/kontinuous/tests/__snapshots__/metabase.prod.yaml index 3f6540e21..9e6f73196 100644 --- a/packages/kontinuous/tests/__snapshots__/metabase.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/metabase.prod.yaml @@ -380,14 +380,12 @@ spec: successThreshold: 1 timeoutSeconds: 10 readinessProbe: - failureThreshold: 15 - httpGet: - path: /api/health - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 livenessProbe: failureThreshold: 6 httpGet: @@ -403,6 +401,25 @@ spec: requests: cpu: 500m memory: 512Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -484,14 +501,12 @@ spec: successThreshold: 1 timeoutSeconds: 10 readinessProbe: - failureThreshold: 15 - httpGet: - path: /api/health - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 livenessProbe: failureThreshold: 6 httpGet: @@ -507,6 +522,25 @@ spec: requests: cpu: 500m memory: 512Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/multi-containers.dev.yaml b/packages/kontinuous/tests/__snapshots__/multi-containers.dev.yaml index 8c368d582..b0046e849 100644 --- a/packages/kontinuous/tests/__snapshots__/multi-containers.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/multi-containers.dev.yaml @@ -133,6 +133,29 @@ spec: requests: cpu: 1 memory: 10Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + readinessProbe: + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check - name: b image: debian:stable resources: @@ -142,5 +165,31 @@ spec: requests: cpu: 1 memory: 10Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + readinessProbe: + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} " `; diff --git a/packages/kontinuous/tests/__snapshots__/needs-using-argocd-sync-waves.dev.yaml b/packages/kontinuous/tests/__snapshots__/needs-using-argocd-sync-waves.dev.yaml index 45c11336f..c318595d1 100644 --- a/packages/kontinuous/tests/__snapshots__/needs-using-argocd-sync-waves.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/needs-using-argocd-sync-waves.dev.yaml @@ -164,14 +164,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -185,6 +183,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -273,14 +290,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -294,6 +309,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -382,14 +416,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -403,6 +435,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -491,14 +542,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -512,6 +561,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -600,14 +668,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -621,6 +687,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -709,14 +794,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -730,6 +813,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/oauth2-proxy-metabase.prod.yaml b/packages/kontinuous/tests/__snapshots__/oauth2-proxy-metabase.prod.yaml index 58b350b4e..19d1def78 100644 --- a/packages/kontinuous/tests/__snapshots__/oauth2-proxy-metabase.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/oauth2-proxy-metabase.prod.yaml @@ -190,14 +190,12 @@ spec: successThreshold: 1 timeoutSeconds: 10 readinessProbe: - failureThreshold: 15 - httpGet: - path: /api/health - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 livenessProbe: failureThreshold: 6 httpGet: @@ -213,6 +211,25 @@ spec: requests: cpu: 500m memory: 512Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -289,14 +306,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /ping - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -312,6 +327,25 @@ spec: envFrom: - secretRef: name: some-secret + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/oauth2-proxy.prod.yaml b/packages/kontinuous/tests/__snapshots__/oauth2-proxy.prod.yaml index 438192c80..a26b67464 100644 --- a/packages/kontinuous/tests/__snapshots__/oauth2-proxy.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/oauth2-proxy.prod.yaml @@ -153,14 +153,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /ping - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -176,6 +174,25 @@ spec: envFrom: - secretRef: name: some-secret + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/persist.dev.yaml b/packages/kontinuous/tests/__snapshots__/persist.dev.yaml index ee6a34b08..af023b5be 100644 --- a/packages/kontinuous/tests/__snapshots__/persist.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/persist.dev.yaml @@ -164,14 +164,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -185,6 +183,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/pg.prod.yaml b/packages/kontinuous/tests/__snapshots__/pg.prod.yaml index da3b36765..1001df138 100644 --- a/packages/kontinuous/tests/__snapshots__/pg.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/pg.prod.yaml @@ -389,14 +389,12 @@ spec: - containerPort: 8080 name: http readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 30 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 resources: limits: cpu: 1 @@ -414,6 +412,25 @@ spec: envFrom: - secretRef: name: cnpg-app + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/pgweb.dev.yaml b/packages/kontinuous/tests/__snapshots__/pgweb.dev.yaml index 629c08b3e..893f17426 100644 --- a/packages/kontinuous/tests/__snapshots__/pgweb.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/pgweb.dev.yaml @@ -176,13 +176,35 @@ spec: path: / port: http readinessProbe: - httpGet: - path: / - port: http + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 resources: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/post-renderer.dev.yaml b/packages/kontinuous/tests/__snapshots__/post-renderer.dev.yaml index 6209f3799..7ec19d521 100644 --- a/packages/kontinuous/tests/__snapshots__/post-renderer.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/post-renderer.dev.yaml @@ -165,14 +165,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -186,6 +184,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/private-mode.dev.yaml b/packages/kontinuous/tests/__snapshots__/private-mode.dev.yaml index 602a530ad..e5a0a39a7 100644 --- a/packages/kontinuous/tests/__snapshots__/private-mode.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/private-mode.dev.yaml @@ -164,14 +164,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -185,8 +183,27 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check imagePullSecrets: - name: harbor-pull-secret + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/project-chart-implicit-enabled.dev.yaml b/packages/kontinuous/tests/__snapshots__/project-chart-implicit-enabled.dev.yaml index bfe2f743f..2ae30696c 100644 --- a/packages/kontinuous/tests/__snapshots__/project-chart-implicit-enabled.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/project-chart-implicit-enabled.dev.yaml @@ -136,5 +136,31 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + readinessProbe: + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} " `; diff --git a/packages/kontinuous/tests/__snapshots__/redis-volume.prod.yaml b/packages/kontinuous/tests/__snapshots__/redis-volume.prod.yaml index 34f81f341..7d4e3c9b9 100644 --- a/packages/kontinuous/tests/__snapshots__/redis-volume.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/redis-volume.prod.yaml @@ -133,6 +133,8 @@ spec: - name: redis persistentVolumeClaim: claimName: redis + - name: readiness-check-volume + emptyDir: {} containers: - image: redis:6.2.6-alpine3.14 name: redis @@ -141,6 +143,8 @@ spec: name: redis - name: redis mountPath: /mnt/redis + - name: readiness-check-volume + mountPath: /var/run/readiness-check ports: - containerPort: 6379 name: http @@ -155,16 +159,12 @@ spec: - -c - redis-cli ping readinessProbe: - failureThreshold: 15 - initialDelaySeconds: 1 - periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 exec: command: - - sh - - -c - - redis-cli ping + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 startupProbe: failureThreshold: 12 periodSeconds: 5 @@ -182,6 +182,19 @@ spec: memory: 128Mi securityContext: allowPrivilegeEscalation: false + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/redis.prod.yaml b/packages/kontinuous/tests/__snapshots__/redis.prod.yaml index 8f236f277..74edbd18c 100644 --- a/packages/kontinuous/tests/__snapshots__/redis.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/redis.prod.yaml @@ -146,16 +146,12 @@ spec: - -c - redis-cli ping readinessProbe: - failureThreshold: 15 - initialDelaySeconds: 1 - periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 exec: command: - - sh - - -c - - redis-cli ping + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 startupProbe: failureThreshold: 12 periodSeconds: 5 @@ -173,6 +169,25 @@ spec: memory: 128Mi securityContext: allowPrivilegeEscalation: false + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/repo.domifa.dev.yaml b/packages/kontinuous/tests/__snapshots__/repo.domifa.dev.yaml index 7e16b6f68..7e26b0cd0 100644 --- a/packages/kontinuous/tests/__snapshots__/repo.domifa.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/repo.domifa.dev.yaml @@ -1967,14 +1967,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -2018,6 +2016,25 @@ spec: name: backend-sealed-secret - configMapRef: name: backend-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -2093,6 +2110,8 @@ spec: volumes: - emptyDir: {} name: files + - name: readiness-check-volume + emptyDir: {} containers: - image: harbor.fabrique.social.gouv.fr/domifa/test-repo.domifa/backend:sha-ffac537e6cbbf934b08745a378932722df287a53 name: app @@ -2108,14 +2127,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -2160,6 +2177,21 @@ spec: volumeMounts: - mountPath: /mnt/files name: files + - name: readiness-check-volume + mountPath: /var/run/readiness-check + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 --- apiVersion: apps/v1 kind: Deployment @@ -2247,14 +2279,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -2268,6 +2298,25 @@ spec: requests: cpu: \\"0.2\\" memory: 256Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -2355,14 +2404,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -2376,6 +2423,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -2463,14 +2529,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -2484,6 +2548,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/repo.domifa.preprod.yaml b/packages/kontinuous/tests/__snapshots__/repo.domifa.preprod.yaml index 40b909def..13114da52 100644 --- a/packages/kontinuous/tests/__snapshots__/repo.domifa.preprod.yaml +++ b/packages/kontinuous/tests/__snapshots__/repo.domifa.preprod.yaml @@ -1340,14 +1340,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1391,6 +1389,25 @@ spec: name: backend-sealed-secret - configMapRef: name: backend-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -1467,6 +1484,8 @@ spec: - name: files persistentVolumeClaim: claimName: files + - name: readiness-check-volume + emptyDir: {} containers: - image: harbor.fabrique.social.gouv.fr/domifa/test-repo.domifa/backend:preprod-ffac537e6cbbf934b08745a378932722df287a53 name: app @@ -1482,14 +1501,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1536,6 +1553,21 @@ spec: volumeMounts: - name: files mountPath: /mnt/files + - name: readiness-check-volume + mountPath: /var/run/readiness-check + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 --- apiVersion: apps/v1 kind: Deployment @@ -1623,14 +1655,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1644,6 +1674,25 @@ spec: requests: cpu: \\"0.2\\" memory: 256Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -1731,14 +1780,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1752,6 +1799,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -1839,14 +1905,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1860,6 +1924,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/repo.domifa.prod.yaml b/packages/kontinuous/tests/__snapshots__/repo.domifa.prod.yaml index d3702e188..0b8265493 100644 --- a/packages/kontinuous/tests/__snapshots__/repo.domifa.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/repo.domifa.prod.yaml @@ -1389,6 +1389,8 @@ spec: - name: files persistentVolumeClaim: claimName: files + - name: readiness-check-volume + emptyDir: {} containers: - image: harbor.fabrique.social.gouv.fr/domifa/test-repo.domifa/backend:prod name: app @@ -1404,14 +1406,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1460,6 +1460,21 @@ spec: volumeMounts: - name: files mountPath: /mnt/files + - name: readiness-check-volume + mountPath: /var/run/readiness-check + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 --- apiVersion: apps/v1 kind: Deployment @@ -1536,6 +1551,8 @@ spec: - name: files persistentVolumeClaim: claimName: files + - name: readiness-check-volume + emptyDir: {} containers: - image: harbor.fabrique.social.gouv.fr/domifa/test-repo.domifa/backend:prod name: app @@ -1551,14 +1568,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1607,6 +1622,21 @@ spec: volumeMounts: - name: files mountPath: /mnt/files + - name: readiness-check-volume + mountPath: /var/run/readiness-check + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 --- apiVersion: apps/v1 kind: Deployment @@ -1694,14 +1724,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1715,6 +1743,25 @@ spec: requests: cpu: \\"0.2\\" memory: 256Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -1802,14 +1849,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1823,6 +1868,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -1910,14 +1974,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -1931,6 +1993,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/sample-1.dev.yaml b/packages/kontinuous/tests/__snapshots__/sample-1.dev.yaml index 136286720..0a590e4c5 100644 --- a/packages/kontinuous/tests/__snapshots__/sample-1.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/sample-1.dev.yaml @@ -243,14 +243,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -271,6 +269,25 @@ spec: name: app-sealed-secret - configMapRef: name: app-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -349,6 +366,8 @@ spec: - name: docs persistentVolumeClaim: claimName: docs + - name: readiness-check-volume + emptyDir: {} containers: - image: harbor.fabrique.social.gouv.fr/test-sample-1/app:sha-ffac537e6cbbf934b08745a378932722df287a53 name: app @@ -364,14 +383,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -397,6 +414,21 @@ spec: name: upload - name: docs mountPath: /mnt/docs + - name: readiness-check-volume + mountPath: /var/run/readiness-check + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 --- apiVersion: apps/v1 kind: Deployment @@ -465,14 +497,12 @@ spec: - containerPort: 8080 name: http readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 30 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 resources: limits: cpu: 1 @@ -494,6 +524,25 @@ spec: name: hasura-sealed-secret - configMapRef: name: hasura-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -570,13 +619,35 @@ spec: path: / port: http readinessProbe: - httpGet: - path: / - port: http + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 resources: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/sample-1.preprod.yaml b/packages/kontinuous/tests/__snapshots__/sample-1.preprod.yaml index 28f5257cf..57e50309d 100644 --- a/packages/kontinuous/tests/__snapshots__/sample-1.preprod.yaml +++ b/packages/kontinuous/tests/__snapshots__/sample-1.preprod.yaml @@ -242,14 +242,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -270,6 +268,25 @@ spec: name: app-sealed-secret - configMapRef: name: app-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -356,14 +373,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -384,6 +399,25 @@ spec: name: app-sealed-secret - configMapRef: name: app-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -451,14 +485,12 @@ spec: - containerPort: 8080 name: http readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 30 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 resources: limits: cpu: 1 @@ -480,6 +512,25 @@ spec: name: hasura-sealed-secret - configMapRef: name: hasura-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -555,13 +606,35 @@ spec: path: / port: http readinessProbe: - httpGet: - path: / - port: http + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 resources: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/sample-1.prod.yaml b/packages/kontinuous/tests/__snapshots__/sample-1.prod.yaml index 50235d7d7..5a9eadf79 100644 --- a/packages/kontinuous/tests/__snapshots__/sample-1.prod.yaml +++ b/packages/kontinuous/tests/__snapshots__/sample-1.prod.yaml @@ -238,14 +238,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -266,6 +264,25 @@ spec: name: app-sealed-secret - configMapRef: name: app-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -352,14 +369,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -380,6 +395,25 @@ spec: name: app-sealed-secret - configMapRef: name: app-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -447,14 +481,12 @@ spec: - containerPort: 8080 name: http readinessProbe: - failureThreshold: 15 - httpGet: - path: /healthz - port: http - initialDelaySeconds: 30 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 resources: limits: cpu: 1 @@ -476,6 +508,25 @@ spec: name: hasura-sealed-secret - configMapRef: name: hasura-configmap + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: apps/v1 kind: Deployment @@ -551,13 +602,35 @@ spec: path: / port: http readinessProbe: - httpGet: - path: / - port: http + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 + periodSeconds: 5 resources: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/socialgouv-autodevops-override.dev.yaml b/packages/kontinuous/tests/__snapshots__/socialgouv-autodevops-override.dev.yaml index 79d83748d..0837ef0ea 100644 --- a/packages/kontinuous/tests/__snapshots__/socialgouv-autodevops-override.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/socialgouv-autodevops-override.dev.yaml @@ -448,14 +448,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -469,6 +467,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/socialgouv-autodevops.dev.yaml b/packages/kontinuous/tests/__snapshots__/socialgouv-autodevops.dev.yaml index 5b5c6be9b..78525b575 100644 --- a/packages/kontinuous/tests/__snapshots__/socialgouv-autodevops.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/socialgouv-autodevops.dev.yaml @@ -447,14 +447,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -468,6 +466,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/values-extends.dev.yaml b/packages/kontinuous/tests/__snapshots__/values-extends.dev.yaml index dc457e243..12a95edc7 100644 --- a/packages/kontinuous/tests/__snapshots__/values-extends.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/values-extends.dev.yaml @@ -299,14 +299,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -320,6 +318,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/values-extends.preprod.yaml b/packages/kontinuous/tests/__snapshots__/values-extends.preprod.yaml index 45e708cad..061bfa1f6 100644 --- a/packages/kontinuous/tests/__snapshots__/values-extends.preprod.yaml +++ b/packages/kontinuous/tests/__snapshots__/values-extends.preprod.yaml @@ -299,14 +299,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -320,6 +318,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service diff --git a/packages/kontinuous/tests/__snapshots__/values-js.dev.yaml b/packages/kontinuous/tests/__snapshots__/values-js.dev.yaml index c911f9004..d7ae739ec 100644 --- a/packages/kontinuous/tests/__snapshots__/values-js.dev.yaml +++ b/packages/kontinuous/tests/__snapshots__/values-js.dev.yaml @@ -163,14 +163,12 @@ spec: periodSeconds: 5 timeoutSeconds: 5 readinessProbe: - failureThreshold: 15 - httpGet: - path: /index.html - port: http - initialDelaySeconds: 1 + exec: + command: + - cat + - /var/run/readiness-check/readiness-file + initialDelaySeconds: 5 periodSeconds: 5 - successThreshold: 1 - timeoutSeconds: 1 startupProbe: failureThreshold: 12 httpGet: @@ -184,6 +182,25 @@ spec: requests: cpu: 81m memory: 262Mi + lifecycle: + postStart: + exec: + command: + - sh + - -c + - touch /var/run/readiness-check/readiness-file + preStop: + exec: + command: + - sh + - -c + - rm -f /var/run/readiness-check/readiness-file; sleep 30 + volumeMounts: + - name: readiness-check-volume + mountPath: /var/run/readiness-check + volumes: + - name: readiness-check-volume + emptyDir: {} --- apiVersion: v1 kind: Service