perf(ci): allow two concurrent non-production deploys
This commit is contained in:
@@ -241,7 +241,7 @@ deploy_local() {
|
||||
docker pull "$IMAGE"
|
||||
export DEPLOY_ENV IMAGE_REPOSITORY IMAGE_TAG
|
||||
new_started=true
|
||||
if ! local_compose up -d --remove-orphans --pull never "$SERVICE"; then
|
||||
if ! local_compose up -d --no-deps --pull never "$SERVICE"; then
|
||||
echo "新镜像启动命令失败: $IMAGE" >&2
|
||||
new_started=false
|
||||
fi
|
||||
@@ -281,7 +281,7 @@ deploy_local() {
|
||||
fi
|
||||
IMAGE_TAG="$previous_tag"
|
||||
export IMAGE_TAG
|
||||
if ! local_compose up -d --remove-orphans --pull never "$SERVICE"; then
|
||||
if ! local_compose up -d --no-deps --pull never "$SERVICE"; then
|
||||
echo "自动回滚失败,旧镜像启动命令失败: $previous_image" >&2
|
||||
return 1
|
||||
fi
|
||||
@@ -436,7 +436,7 @@ else
|
||||
fi
|
||||
|
||||
new_started=true
|
||||
if ! compose up -d --remove-orphans --pull never "$service"; then
|
||||
if ! compose up -d --no-deps --pull never "$service"; then
|
||||
echo "新镜像启动命令失败: $new_image" >&2
|
||||
new_started=false
|
||||
fi
|
||||
@@ -472,7 +472,7 @@ if ! docker pull "$previous_image"; then
|
||||
fi
|
||||
IMAGE_TAG="$previous_tag"
|
||||
export IMAGE_TAG
|
||||
if ! compose up -d --remove-orphans --pull never "$service"; then
|
||||
if ! compose up -d --no-deps --pull never "$service"; then
|
||||
echo "自动回滚失败,旧镜像启动命令失败: $previous_image" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user