From 713b7f563ccf3cf416e5b9305b223f85edea3f55 Mon Sep 17 00:00:00 2001 From: Michael Hotan Date: Mon, 24 Jun 2024 10:52:31 -0700 Subject: [PATCH] flyteconsole readiness & liveness probe (#337) Make flyteconsole readiness & liveness probe configurable --- charts/flyte-core/README.md | 2 ++ charts/flyte-core/templates/console/deployment.yaml | 8 ++++++++ charts/flyte-core/values.yaml | 3 +++ docker/sandbox-bundled/manifests/complete-agent.yaml | 4 ++-- docker/sandbox-bundled/manifests/complete.yaml | 4 ++-- docker/sandbox-bundled/manifests/dev.yaml | 4 ++-- 6 files changed, 19 insertions(+), 6 deletions(-) diff --git a/charts/flyte-core/README.md b/charts/flyte-core/README.md index 11b1030ada3..37037076605 100644 --- a/charts/flyte-core/README.md +++ b/charts/flyte-core/README.md @@ -209,11 +209,13 @@ helm install gateway bitnami/contour -n flyte | flyteconsole.image.repository | string | `"cr.flyte.org/flyteorg/flyteconsole"` | Docker image for Flyteconsole deployment | | flyteconsole.image.tag | string | `"v1.14.0"` | | | flyteconsole.imagePullSecrets | list | `[]` | ImagePullSecrets to assign to the Flyteconsole deployment | +| flyteconsole.livenessProbe | object | `{}` | | | flyteconsole.nodeSelector | object | `{}` | nodeSelector for Flyteconsole deployment | | flyteconsole.podAnnotations | object | `{}` | Annotations for Flyteconsole pods | | flyteconsole.podEnv | object | `{}` | Additional Flyteconsole container environment variables | | flyteconsole.podLabels | object | `{}` | Labels for Flyteconsole pods | | flyteconsole.priorityClassName | string | `""` | Sets priorityClassName for flyte console pod(s). | +| flyteconsole.readinessProbe | object | `{}` | | | flyteconsole.replicaCount | int | `1` | Replicas count for Flyteconsole deployment | | flyteconsole.resources | object | `{"limits":{"cpu":"500m","memory":"250Mi"},"requests":{"cpu":"10m","memory":"50Mi"}}` | Default resources requests and limits for Flyteconsole deployment | | flyteconsole.securityContext | object | `{"fsGroupChangePolicy":"OnRootMismatch","runAsNonRoot":true,"runAsUser":1000,"seLinuxOptions":{"type":"spc_t"}}` | Sets securityContext for flyteconsole pod(s). | diff --git a/charts/flyte-core/templates/console/deployment.yaml b/charts/flyte-core/templates/console/deployment.yaml index 7d089b3b5ea..834b3cf84c5 100644 --- a/charts/flyte-core/templates/console/deployment.yaml +++ b/charts/flyte-core/templates/console/deployment.yaml @@ -64,6 +64,14 @@ spec: volumeMounts: - mountPath: /srv/flyte name: shared-data + {{- with .Values.flyteconsole.livenessProbe }} + livenessProbe: + {{- toYaml . | nindent 10 }} + {{- end }} + {{- with .Values.flyteconsole.readinessProbe }} + readinessProbe: + {{- toYaml . | nindent 10 }} + {{- end }} volumes: - emptyDir: {} name: shared-data diff --git a/charts/flyte-core/values.yaml b/charts/flyte-core/values.yaml index 02ff3a54ab0..3f2932ad4b7 100755 --- a/charts/flyte-core/values.yaml +++ b/charts/flyte-core/values.yaml @@ -454,6 +454,9 @@ flyteconsole: # prometheus to auto-detect the service monitor and start scrapping the metrics labels: {} + livenessProbe: {} + readinessProbe: {} + # It will enable the redoc route in ingress deployRedoc: false diff --git a/docker/sandbox-bundled/manifests/complete-agent.yaml b/docker/sandbox-bundled/manifests/complete-agent.yaml index f43ba75b4e7..f261cb26235 100644 --- a/docker/sandbox-bundled/manifests/complete-agent.yaml +++ b/docker/sandbox-bundled/manifests/complete-agent.yaml @@ -816,7 +816,7 @@ type: Opaque --- apiVersion: v1 data: - haSharedSecret: Qm5HWVV1QUFNb3YxbW45WQ== + haSharedSecret: RXVLTERoMzJHdktxQlo4cQ== proxyPassword: "" proxyUsername: "" kind: Secret @@ -1412,7 +1412,7 @@ spec: metadata: annotations: checksum/config: 8f50e768255a87f078ba8b9879a0c174c3e045ffb46ac8723d2eedbe293c8d81 - checksum/secret: 64a35ebb21d379461a7846f02d38e59d6e09c2cf53f5254a3eee3f9c91464887 + checksum/secret: 3154841b4ef47e9abff94afa4fb18f019a8ab1bd3bfd067ee69c58a6cfa72850 labels: app: docker-registry release: flyte-sandbox diff --git a/docker/sandbox-bundled/manifests/complete.yaml b/docker/sandbox-bundled/manifests/complete.yaml index 07850d61710..ff5ba90edd0 100644 --- a/docker/sandbox-bundled/manifests/complete.yaml +++ b/docker/sandbox-bundled/manifests/complete.yaml @@ -796,7 +796,7 @@ type: Opaque --- apiVersion: v1 data: - haSharedSecret: cllsN0RhMWZlcHloeGZrZg== + haSharedSecret: dmJQRFJKUkkxNUM4YlJVQg== proxyPassword: "" proxyUsername: "" kind: Secret @@ -1360,7 +1360,7 @@ spec: metadata: annotations: checksum/config: 8f50e768255a87f078ba8b9879a0c174c3e045ffb46ac8723d2eedbe293c8d81 - checksum/secret: 8ca680f0c05182912281c1d391564a95daddb1472d6b517abe2d61019cc33935 + checksum/secret: 08894598b0a7ca264bfe377c29916b437ba3afbfcc12d664e0c28285913fca2c labels: app: docker-registry release: flyte-sandbox diff --git a/docker/sandbox-bundled/manifests/dev.yaml b/docker/sandbox-bundled/manifests/dev.yaml index 8853bf91f66..5692b7e353a 100644 --- a/docker/sandbox-bundled/manifests/dev.yaml +++ b/docker/sandbox-bundled/manifests/dev.yaml @@ -499,7 +499,7 @@ metadata: --- apiVersion: v1 data: - haSharedSecret: Um0xN045YzNQM3BpejM4cg== + haSharedSecret: amQ2V3I1QWxxWE5FR3ptbA== proxyPassword: "" proxyUsername: "" kind: Secret @@ -934,7 +934,7 @@ spec: metadata: annotations: checksum/config: 8f50e768255a87f078ba8b9879a0c174c3e045ffb46ac8723d2eedbe293c8d81 - checksum/secret: 9ef10229438d994b621886d5c5f3e327fd344e76c00a287efe9aaeec4b3f8e49 + checksum/secret: 21b7819320348d53868271005a964a9644a024a2ea50c0936db78e55d1a923e3 labels: app: docker-registry release: flyte-sandbox