From 65c791e47371ad7c13ffc813323cf7b5ca906d3f Mon Sep 17 00:00:00 2001 From: Kevin Su Date: Fri, 1 Mar 2024 14:27:29 -0800 Subject: [PATCH 1/4] Add gRPC probe for agent Signed-off-by: Kevin Su --- charts/flyteagent/templates/agent/deployment.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/charts/flyteagent/templates/agent/deployment.yaml b/charts/flyteagent/templates/agent/deployment.yaml index 2c6a903f8f..35efac5e5b 100644 --- a/charts/flyteagent/templates/agent/deployment.yaml +++ b/charts/flyteagent/templates/agent/deployment.yaml @@ -39,6 +39,10 @@ spec: ports: - containerPort: {{ .Values.ports.containerPort }} name: {{ .Values.ports.name }} + readinessProbe: + grpc: + port: {{ .Values.ports.containerPort }} + initialDelaySeconds: 5 securityContext: {{- toYaml .Values.securityContext | nindent 12 }} resources: {{- toYaml .Values.resources | nindent 10 }} From df73d36778dcacf5972ea2e04e94c09f7929458f Mon Sep 17 00:00:00 2001 From: Kevin Su Date: Mon, 4 Mar 2024 15:04:07 -0800 Subject: [PATCH 2/4] update image Signed-off-by: Kevin Su --- charts/flyteagent/templates/agent/deployment.yaml | 6 +++--- charts/flyteagent/values.yaml | 8 +++++++- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/charts/flyteagent/templates/agent/deployment.yaml b/charts/flyteagent/templates/agent/deployment.yaml index 35efac5e5b..caad9ca44a 100644 --- a/charts/flyteagent/templates/agent/deployment.yaml +++ b/charts/flyteagent/templates/agent/deployment.yaml @@ -40,9 +40,9 @@ spec: - containerPort: {{ .Values.ports.containerPort }} name: {{ .Values.ports.name }} readinessProbe: - grpc: - port: {{ .Values.ports.containerPort }} - initialDelaySeconds: 5 + {{- with .Values.readinessProbe -}} + {{ tpl (toYaml .) $ | nindent 10 }} + {{- end }} securityContext: {{- toYaml .Values.securityContext | nindent 12 }} resources: {{- toYaml .Values.resources | nindent 10 }} diff --git a/charts/flyteagent/values.yaml b/charts/flyteagent/values.yaml index aee84dc2b2..cc4a442251 100755 --- a/charts/flyteagent/values.yaml +++ b/charts/flyteagent/values.yaml @@ -23,7 +23,7 @@ image: # -- Docker image for flyteagent deployment repository: ghcr.io/flyteorg/flyteagent # -- Docker image tag - tag: 1.10.7 # FLYTEAGENT_TAG + tag: 1.10.8 # FLYTEAGENT_TAG # -- Docker image pull policy pullPolicy: IfNotPresent ports: @@ -56,6 +56,12 @@ serviceAccount: imagePullSecrets: [] # -- Security context for pod podSecurityContext: {} +# -- Readiness probe for flyteagent. Use readinessProbe: {} if agent doesn't implement grpc-health-checking service. +# -- https://kubernetes.io/blog/2022/05/13/grpc-probes-now-in-beta/#trying-the-feature-out +readinessProbe: + grpc: + port: 8000 + initialDelaySeconds: 5 # -- Security context for container securityContext: allowPrivilegeEscalation: false From 76d03e41b2f0d20f8cc96af5dac45e2213d8c382 Mon Sep 17 00:00:00 2001 From: Kevin Su Date: Wed, 6 Mar 2024 00:02:06 -0800 Subject: [PATCH 3/4] make helm Signed-off-by: Kevin Su --- charts/flyteagent/README.md | 3 ++- charts/flyteagent/values.yaml | 2 +- deployment/agent/flyte_agent_helm_generated.yaml | 6 +++++- docker/sandbox-bundled/manifests/complete-agent.yaml | 10 +++++++--- docker/sandbox-bundled/manifests/complete.yaml | 4 ++-- docker/sandbox-bundled/manifests/dev.yaml | 4 ++-- 6 files changed, 19 insertions(+), 10 deletions(-) diff --git a/charts/flyteagent/README.md b/charts/flyteagent/README.md index f889c095bd..e193c2d887 100644 --- a/charts/flyteagent/README.md +++ b/charts/flyteagent/README.md @@ -20,7 +20,7 @@ A Helm chart for Flyte agent | fullnameOverride | string | `""` | | | image.pullPolicy | string | `"IfNotPresent"` | Docker image pull policy | | image.repository | string | `"ghcr.io/flyteorg/flyteagent"` | Docker image for flyteagent deployment | -| image.tag | string | `"1.10.7"` | Docker image tag | +| image.tag | string | `"1.10.8b2"` | Docker image tag | | nameOverride | string | `""` | | | nodeSelector | object | `{}` | nodeSelector for flyteagent deployment | | podAnnotations | object | `{}` | Annotations for flyteagent pods | @@ -30,6 +30,7 @@ A Helm chart for Flyte agent | ports.containerPort | int | `8000` | | | ports.name | string | `"agent-grpc"` | | | priorityClassName | string | `""` | Sets priorityClassName for datacatalog pod(s). | +| readinessProbe | object | `{"grpc":{"port":8000},"initialDelaySeconds":5}` | https://kubernetes.io/blog/2022/05/13/grpc-probes-now-in-beta/#trying-the-feature-out | | replicaCount | int | `1` | Replicas count for flyteagent deployment | | resources | object | `{"limits":{"cpu":"500m","ephemeral-storage":"200Mi","memory":"200Mi"},"requests":{"cpu":"500m","ephemeral-storage":"200Mi","memory":"200Mi"}}` | Default resources requests and limits for flyteagent deployment | | securityContext | object | `{"allowPrivilegeEscalation":false}` | Security context for container | diff --git a/charts/flyteagent/values.yaml b/charts/flyteagent/values.yaml index cc4a442251..0214490b70 100755 --- a/charts/flyteagent/values.yaml +++ b/charts/flyteagent/values.yaml @@ -23,7 +23,7 @@ image: # -- Docker image for flyteagent deployment repository: ghcr.io/flyteorg/flyteagent # -- Docker image tag - tag: 1.10.8 # FLYTEAGENT_TAG + tag: 1.10.8b2 # FLYTEAGENT_TAG # -- Docker image pull policy pullPolicy: IfNotPresent ports: diff --git a/deployment/agent/flyte_agent_helm_generated.yaml b/deployment/agent/flyte_agent_helm_generated.yaml index 46762b4cff..2cdb47f621 100644 --- a/deployment/agent/flyte_agent_helm_generated.yaml +++ b/deployment/agent/flyte_agent_helm_generated.yaml @@ -78,7 +78,7 @@ spec: - pyflyte - serve - agent - image: "ghcr.io/flyteorg/flyteagent:1.10.7" + image: "ghcr.io/flyteorg/flyteagent:1.10.8b2" imagePullPolicy: "IfNotPresent" name: flyteagent volumeMounts: @@ -87,6 +87,10 @@ spec: ports: - containerPort: 8000 name: agent-grpc + readinessProbe: + grpc: + port: 8000 + initialDelaySeconds: 5 securityContext: allowPrivilegeEscalation: false resources: diff --git a/docker/sandbox-bundled/manifests/complete-agent.yaml b/docker/sandbox-bundled/manifests/complete-agent.yaml index 6de7c86be9..f3b70f9af4 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: UDI2NklEa2dSNUhNeTFteA== + haSharedSecret: aXMxM0ZiZFBUQTVKQzZzag== proxyPassword: "" proxyUsername: "" kind: Secret @@ -1412,7 +1412,7 @@ spec: metadata: annotations: checksum/config: 8f50e768255a87f078ba8b9879a0c174c3e045ffb46ac8723d2eedbe293c8d81 - checksum/secret: d57403ae8ea0fce27bceda25f6af446fe51652e99e95a07fddae387006ee29f1 + checksum/secret: 5efa2a8b90cb09695695fe2117018010cba089397a6ec9b91191e1ba1cdb7ee0 labels: app: docker-registry release: flyte-sandbox @@ -1755,12 +1755,16 @@ spec: value: minio - name: FLYTE_AWS_SECRET_ACCESS_KEY value: miniostorage - image: ghcr.io/flyteorg/flyteagent:1.10.7 + image: ghcr.io/flyteorg/flyteagent:1.10.8b2 imagePullPolicy: IfNotPresent name: flyteagent ports: - containerPort: 8000 name: agent-grpc + readinessProbe: + grpc: + port: 8000 + initialDelaySeconds: 5 resources: limits: cpu: 500m diff --git a/docker/sandbox-bundled/manifests/complete.yaml b/docker/sandbox-bundled/manifests/complete.yaml index b56e367ac4..a6a0cb641e 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: T21pWVJOUEdxMXBTSVE1RQ== + haSharedSecret: YjFvdVhNdW52SHpKQ2FJSw== proxyPassword: "" proxyUsername: "" kind: Secret @@ -1360,7 +1360,7 @@ spec: metadata: annotations: checksum/config: 8f50e768255a87f078ba8b9879a0c174c3e045ffb46ac8723d2eedbe293c8d81 - checksum/secret: b0e1d465fbab24856443e463cb7846c898d03f1e00ac443b08e5474d28418ba3 + checksum/secret: 2963c5428fd79c68e963854f7c4154d3f2dec35e6a52c93d0e7807205aa7c43c labels: app: docker-registry release: flyte-sandbox diff --git a/docker/sandbox-bundled/manifests/dev.yaml b/docker/sandbox-bundled/manifests/dev.yaml index 2a8383a1dd..69624160e0 100644 --- a/docker/sandbox-bundled/manifests/dev.yaml +++ b/docker/sandbox-bundled/manifests/dev.yaml @@ -499,7 +499,7 @@ metadata: --- apiVersion: v1 data: - haSharedSecret: bGRYdlJtdmZ5Qm14ZEJnNg== + haSharedSecret: MTg1TFE5S0JzU2NJNjM0NQ== proxyPassword: "" proxyUsername: "" kind: Secret @@ -934,7 +934,7 @@ spec: metadata: annotations: checksum/config: 8f50e768255a87f078ba8b9879a0c174c3e045ffb46ac8723d2eedbe293c8d81 - checksum/secret: b3f9230da427e818d5a63cbbf15159f2b165c98e6f56e269983c0a8fff6b6099 + checksum/secret: 1711d3d34542992ce0d26da8299f55a0c534553eae7ba7dfb6b1151b87f52e98 labels: app: docker-registry release: flyte-sandbox From e3a9adb7f1de496d40900658a0008d784200560f Mon Sep 17 00:00:00 2001 From: Future-Outlier Date: Wed, 6 Mar 2024 21:57:54 +0800 Subject: [PATCH 4/4] test Signed-off-by: Future-Outlier --- charts/flyteagent/README.md | 2 +- charts/flyteagent/values.yaml | 2 +- deployment/agent/flyte_agent_helm_generated.yaml | 2 +- docker/sandbox-bundled/manifests/complete-agent.yaml | 6 +++--- docker/sandbox-bundled/manifests/complete.yaml | 4 ++-- docker/sandbox-bundled/manifests/dev.yaml | 4 ++-- 6 files changed, 10 insertions(+), 10 deletions(-) diff --git a/charts/flyteagent/README.md b/charts/flyteagent/README.md index e193c2d887..d508823c11 100644 --- a/charts/flyteagent/README.md +++ b/charts/flyteagent/README.md @@ -20,7 +20,7 @@ A Helm chart for Flyte agent | fullnameOverride | string | `""` | | | image.pullPolicy | string | `"IfNotPresent"` | Docker image pull policy | | image.repository | string | `"ghcr.io/flyteorg/flyteagent"` | Docker image for flyteagent deployment | -| image.tag | string | `"1.10.8b2"` | Docker image tag | +| image.tag | string | `"1.10.8b1"` | Docker image tag | | nameOverride | string | `""` | | | nodeSelector | object | `{}` | nodeSelector for flyteagent deployment | | podAnnotations | object | `{}` | Annotations for flyteagent pods | diff --git a/charts/flyteagent/values.yaml b/charts/flyteagent/values.yaml index 0214490b70..ca5fb6c719 100755 --- a/charts/flyteagent/values.yaml +++ b/charts/flyteagent/values.yaml @@ -23,7 +23,7 @@ image: # -- Docker image for flyteagent deployment repository: ghcr.io/flyteorg/flyteagent # -- Docker image tag - tag: 1.10.8b2 # FLYTEAGENT_TAG + tag: 1.10.8b1 # FLYTEAGENT_TAG # -- Docker image pull policy pullPolicy: IfNotPresent ports: diff --git a/deployment/agent/flyte_agent_helm_generated.yaml b/deployment/agent/flyte_agent_helm_generated.yaml index 2cdb47f621..bca0bd11c8 100644 --- a/deployment/agent/flyte_agent_helm_generated.yaml +++ b/deployment/agent/flyte_agent_helm_generated.yaml @@ -78,7 +78,7 @@ spec: - pyflyte - serve - agent - image: "ghcr.io/flyteorg/flyteagent:1.10.8b2" + image: "ghcr.io/flyteorg/flyteagent:1.10.8b1" imagePullPolicy: "IfNotPresent" name: flyteagent volumeMounts: diff --git a/docker/sandbox-bundled/manifests/complete-agent.yaml b/docker/sandbox-bundled/manifests/complete-agent.yaml index 3dc2da8d69..862a0eeda1 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: MDZkcjZpSWtxQ0l1U3BkRg== + haSharedSecret: Zms3SW5vbVJxOHowN1VhVA== proxyPassword: "" proxyUsername: "" kind: Secret @@ -1412,7 +1412,7 @@ spec: metadata: annotations: checksum/config: 8f50e768255a87f078ba8b9879a0c174c3e045ffb46ac8723d2eedbe293c8d81 - checksum/secret: 0e1cd1e2d9516f5d078a3175e0dca1176c488a2a1b26a520ffb5e8567b028371 + checksum/secret: 228ca9f5237a2e92e210abfac8608756d9b4f4e3bb58c540b70084a8c6909872 labels: app: docker-registry release: flyte-sandbox @@ -1755,7 +1755,7 @@ spec: value: minio - name: FLYTE_AWS_SECRET_ACCESS_KEY value: miniostorage - image: ghcr.io/flyteorg/flyteagent:1.10.8b2 + image: ghcr.io/flyteorg/flyteagent:1.10.8b1 imagePullPolicy: IfNotPresent name: flyteagent ports: diff --git a/docker/sandbox-bundled/manifests/complete.yaml b/docker/sandbox-bundled/manifests/complete.yaml index 9f41c7583a..14a74eba0f 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: VmVKR1JscnRLS0NlcGR0aA== + haSharedSecret: OWkyWWU2Tkx3Q2E4QjN3ag== proxyPassword: "" proxyUsername: "" kind: Secret @@ -1360,7 +1360,7 @@ spec: metadata: annotations: checksum/config: 8f50e768255a87f078ba8b9879a0c174c3e045ffb46ac8723d2eedbe293c8d81 - checksum/secret: a0053cd8b344fa27669b64ed7abc8d0579ecce282a81be07cd7d4c07734ac269 + checksum/secret: 020ea6300550849c9012777ee6ebdf5ee7b66b1d947eecae6fd1cf58e113c448 labels: app: docker-registry release: flyte-sandbox diff --git a/docker/sandbox-bundled/manifests/dev.yaml b/docker/sandbox-bundled/manifests/dev.yaml index 6a45fee772..e8053ab67e 100644 --- a/docker/sandbox-bundled/manifests/dev.yaml +++ b/docker/sandbox-bundled/manifests/dev.yaml @@ -499,7 +499,7 @@ metadata: --- apiVersion: v1 data: - haSharedSecret: VFFoSGVGVXNlZG5HamZ0Vw== + haSharedSecret: cTcxcFFSaGpXTFlZYnR5Tw== proxyPassword: "" proxyUsername: "" kind: Secret @@ -934,7 +934,7 @@ spec: metadata: annotations: checksum/config: 8f50e768255a87f078ba8b9879a0c174c3e045ffb46ac8723d2eedbe293c8d81 - checksum/secret: ea52a66e2d5ced849a5c3de4e1877b5bb4f945e9240457b48bb5cdffa3c25b97 + checksum/secret: 4f4fcf36df91f8956caa8d5c82e237324c71787376214f677f25df06331b8074 labels: app: docker-registry release: flyte-sandbox