avoid duplicate staging production build
This commit is contained in:
@@ -33,6 +33,7 @@ jobs:
|
||||
timeout-minutes: 45
|
||||
env:
|
||||
GITEA_SHA: ${{ gitea.sha }}
|
||||
GITEA_EVENT_NAME: ${{ gitea.event_name }}
|
||||
NODE_TOOL_SOURCE_IMAGE: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/library/node:22-bookworm-slim@sha256:ef343465b6a14bbdf2ab52f6e100ec0659a792464fcf72c462370d88b3df909c
|
||||
NODE_TOOL_IMAGE: node:22-bookworm-slim
|
||||
steps:
|
||||
@@ -215,9 +216,13 @@ jobs:
|
||||
python -m build
|
||||
npm test --prefix frontend
|
||||
npm run lint --prefix frontend
|
||||
if ! timeout 600 npm run build --prefix frontend; then
|
||||
echo "frontend production build exceeded bounded 600-second timeout" >&2
|
||||
exit 124
|
||||
if [ "$GITEA_EVENT_NAME" != "push" ]; then
|
||||
if ! timeout 600 npm run build --prefix frontend; then
|
||||
echo "frontend production build exceeded bounded 600-second timeout" >&2
|
||||
exit 124
|
||||
fi
|
||||
else
|
||||
echo "staging push production build is verified once by the publish image build"
|
||||
fi
|
||||
|
||||
publish:
|
||||
|
||||
Reference in New Issue
Block a user