From c0c90fb19d907871ec1a65a0f9e39b0fdbbb4ab0 Mon Sep 17 00:00:00 2001 From: maonamao <2582480639@qq.com> Date: Sat, 27 Dec 2025 14:14:35 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=97=A7pod=E5=BD=B1?= =?UTF-8?q?=E5=93=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/ci-cd.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index d0153ee..a185769 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -120,7 +120,7 @@ jobs: fingerprint: "SHA256:AG7nRpWC+NVXcUCumX0/e+A9Qucyb3yLsIFycJif6Tg" debug: true timeout: 30s - command_timeout: 10m + command_timeout: 30m script: | set -e cd ${{ secrets.DEPLOY_PATH }} @@ -176,9 +176,15 @@ jobs: INACTIVE_TRACK="blue" fi + $KUBECTL -n ecommerce scale deployment/backend-$INACTIVE_TRACK --replicas=0 + $KUBECTL -n ecommerce delete pod -l app=backend,track=$INACTIVE_TRACK --ignore-not-found=true --grace-period=0 --force + $KUBECTL -n ecommerce wait --for=delete pod -l app=backend,track=$INACTIVE_TRACK --timeout=5m || true + $KUBECTL -n ecommerce set image deployment/backend-$INACTIVE_TRACK \ backend=$REGISTRY/backend:$TAG + $KUBECTL -n ecommerce scale deployment/backend-$INACTIVE_TRACK --replicas=1 + $KUBECTL -n ecommerce rollout status deployment/backend-$INACTIVE_TRACK --timeout=10m $KUBECTL -n ecommerce patch svc backend \