Compare commits

..

1 Commits

Author SHA1 Message Date
Sergey Antropoff 65af983dea Raise deploy rollout timeout to 1200s and set images in one step.
Avoid double ReplicaSet churn and ImagePullBackOff races during Hub pulls.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-28 00:56:46 +03:00
Vendored
+8 -12
View File
@@ -146,19 +146,15 @@ pipeline {
echo "Rolling ${DOCKERHUB_IMAGE}:${IMAGE_VERSION} → ${HELM_NAMESPACE}/${DEPLOYMENT_NAME}" echo "Rolling ${DOCKERHUB_IMAGE}:${IMAGE_VERSION} → ${HELM_NAMESPACE}/${DEPLOYMENT_NAME}"
echo "Public URL: https://${INGRESS_HOST}/" echo "Public URL: https://${INGRESS_HOST}/"
# POSIX sh (Alpine ash): no bash arrays. One set-image when migrate exists. # One set-image avoids double ReplicaSet churn; migrate when present.
INITS="$(kubectl -n "$HELM_NAMESPACE" get deploy "$DEPLOYMENT_NAME" \ SET_ARGS=("simulator=${DOCKERHUB_IMAGE}:${IMAGE_VERSION}")
-o jsonpath='{.spec.template.spec.initContainers[*].name}' || true)" if kubectl -n "$HELM_NAMESPACE" get deploy "$DEPLOYMENT_NAME" \
if printf '%s\n' $INITS | grep -qx migrate; then -o jsonpath='{.spec.template.spec.initContainers[*].name}' \
kubectl -n "$HELM_NAMESPACE" set image \ | tr ' ' '\n' | grep -qx migrate; then
"deployment/${DEPLOYMENT_NAME}" \ SET_ARGS+=("migrate=${DOCKERHUB_IMAGE}:${IMAGE_VERSION}")
"simulator=${DOCKERHUB_IMAGE}:${IMAGE_VERSION}" \
"migrate=${DOCKERHUB_IMAGE}:${IMAGE_VERSION}"
else
kubectl -n "$HELM_NAMESPACE" set image \
"deployment/${DEPLOYMENT_NAME}" \
"simulator=${DOCKERHUB_IMAGE}:${IMAGE_VERSION}"
fi fi
kubectl -n "$HELM_NAMESPACE" set image \
"deployment/${DEPLOYMENT_NAME}" "${SET_ARGS[@]}"
kubectl -n "$HELM_NAMESPACE" rollout status \ kubectl -n "$HELM_NAMESPACE" rollout status \
"deployment/${DEPLOYMENT_NAME}" --timeout=1200s "deployment/${DEPLOYMENT_NAME}" --timeout=1200s