ci: build the backend image in its own workflow and shorten the panel offer wait [CI]
ci/woodpecker/push/web-build Pipeline was successful
ci/woodpecker/push/verify Pipeline was successful
ci/woodpecker/push/dev-image Pipeline was successful
ci/woodpecker/push/dev-backend-image Pipeline was successful

This commit is contained in:
justme committed 2026-10-21 15:49:38 +08:00
1 parent 5b1bf09eb0
commit e0f6667cd7
5 files changed
+58 -26

No files matched your search

+6 -6
View File
@@ -2,8 +2,8 @@
# Resolve Backend and Agent dependencies once before Linux build tasks start.
set -euo pipefail
mode="${1:?usage: restore-linux-dependencies.sh <dev|release|agent>}"
case "$mode" in dev|release|agent) ;; *) exit 2 ;; esac
mode="${1:?usage: restore-linux-dependencies.sh <dev-backend|dev-agent|release|agent>}"
case "$mode" in dev-backend|dev-agent|release|agent) ;; *) exit 2 ;; esac
root="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
work="$root/.release/linux-restore"
base_home="/home/justme/woodpecker/buildah-home/linux-agent"
@@ -24,15 +24,15 @@ trap cleanup EXIT
source "$root/ci/version.sh"
export NUGET_PACKAGES="${NUGET_PACKAGES:-/home/justme/woodpecker/cache/nuget/packages}"
mkdir -p "$NUGET_PACKAGES"
if [[ "$mode" == dev ]]; then
if [[ "$mode" == dev-* ]]; then
[[ "${CI_PIPELINE_EVENT:-}" == push && "${CI_COMMIT_BRANCH:-}" == main && "${CI_COMMIT_MESSAGE:-}" == *'[CI]'* ]] || exit 2
else
[[ "${CI_COMMIT_TAG:-}" =~ ^v[0-9]+\.[0-9]+\.[0-9]+(-[0-9A-Za-z.-]+)?$ ]] || exit 2
fi
moshiro_apply_version
if [[ "$mode" == dev || "$mode" == release ]]; then
if [[ "$mode" == dev ]]; then
if [[ "$mode" == dev-backend || "$mode" == release ]]; then
if [[ "$mode" == dev-backend ]]; then
backend_rids=(linux-x64)
else
backend_rids=(linux-x64 linux-arm64)
@@ -52,7 +52,7 @@ if [[ "$mode" == dev || "$mode" == release ]]; then
done
fi
if [[ "$mode" == dev || "$mode" == agent ]]; then
if [[ "$mode" == dev-agent || "$mode" == agent ]]; then
[[ "${CI_COMMIT_SHA:-}" =~ ^[0-9a-fA-F]{40}$ ]] || { echo 'CI_COMMIT_SHA must be a full commit SHA' >&2; exit 2; }
mkdir -p "$work" "$base_home"
exec 9> "$base_home/.lock"