adrfhhda
CI / Load gitea-env.conf to pipeline env (push) Successful in 12s
ci-check Build version 0.1.0 required
ci-cucumber Cucumber tests
ci-bats Bats tests
ci-build Build complete
ci-docker-push Docker push 0.1.0 FAILED
CI / Build & Push Artifact (push) Failing after 3m28s

This commit is contained in:
moilanik
2026-06-15 09:53:58 +03:00
parent 0efd7db43a
commit 0740dbf815
+18 -20
View File
@@ -91,7 +91,6 @@ jobs:
quality-gate: quality-gate:
needs: [check] needs: [check]
if: needs.check.outputs.artifact_exists == 'false'
uses: niko/gitea-ci-library/.gitea/workflows/quality-gate.yml@main uses: niko/gitea-ci-library/.gitea/workflows/quality-gate.yml@main
secrets: inherit secrets: inherit
with: with:
@@ -102,8 +101,10 @@ jobs:
build: build:
runs-on: ubuntu-latest runs-on: ubuntu-latest
needs: [check, quality-gate] needs: [check, quality-gate]
# TIUKKA NATIIVI EHTO: Jos testit feilasivat, tämä EI käynnisty koskaan (koko putki punaiselle) # LÖYSÄTTY EHTO: Vaaditaan vain, että check-job meni onnistuneesti läpi.
if: success() # Quality gate vastuulla on räjäyttää koko job jos se ei mene läpi!
# Tämä sallii sen, että quality-gate voi olla Gitean muuttujissa tyhjä, eikä build-job enää ohitu (skip).
if: always()
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
@@ -113,19 +114,6 @@ jobs:
name: build-context name: build-context
path: /tmp/build-ctx path: /tmp/build-ctx
- name: Gatekeeper check
id: gatekeeper
run: |
source /tmp/build-ctx/build.env
echo "gitea-ci-library - Levyltä luettu ARTIFACT_EXISTS: $ARTIFACT_EXISTS"
if [ "$ARTIFACT_EXISTS" = "true" ]; then
echo "gitea-ci-library - Kontti valmiina. Ohitetaan build-vaiheet."
echo "skip=true" >> "$GITHUB_OUTPUT"
else
echo "skip=false" >> "$GITHUB_OUTPUT"
fi
- name: Set Gitea status to PENDING - name: Set Gitea status to PENDING
if: steps.gatekeeper.outputs.skip == 'false' if: steps.gatekeeper.outputs.skip == 'false'
run: | run: |
@@ -172,7 +160,7 @@ jobs:
push: push:
runs-on: ubuntu-latest runs-on: ubuntu-latest
needs: [check, build] needs: [check, build]
if: success() if: always()
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
@@ -182,10 +170,15 @@ jobs:
name: build-context name: build-context
path: /tmp/build-ctx path: /tmp/build-ctx
- name: Gatekeeper check - name: Verify Build Status
id: gatekeeper id: gatekeeper
run: | run: |
BUILD_RESULT="${{ needs.build.result }}"
source /tmp/build-ctx/build.env source /tmp/build-ctx/build.env
if [ "$BUILD_RESULT" != "success" ]; then
echo "gitea-ci-library - Edellinen vaihe epäonnistui. Keskeytetään." >&2
exit 1
fi
if [ "${ARTIFACT_EXISTS}" = "true" ]; then if [ "${ARTIFACT_EXISTS}" = "true" ]; then
echo "skip=true" >> "$GITHUB_OUTPUT" echo "skip=true" >> "$GITHUB_OUTPUT"
else else
@@ -234,7 +227,7 @@ jobs:
tag-commit: tag-commit:
runs-on: ubuntu-latest runs-on: ubuntu-latest
needs: [check, push] needs: [check, push]
if: success() if: always()
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
@@ -244,10 +237,15 @@ jobs:
name: build-context name: build-context
path: /tmp/build-ctx path: /tmp/build-ctx
- name: Gatekeeper check - name: Verify Push Status
id: gatekeeper id: gatekeeper
run: | run: |
PUSH_RESULT="${{ needs.push.result }}"
source /tmp/build-ctx/build.env source /tmp/build-ctx/build.env
if [ "$PUSH_RESULT" != "success" ]; then
echo "gitea-ci-library - Push vaihe epäonnistui. Keskeytetään." >&2
exit 1
fi
if [ "${ARTIFACT_EXISTS}" = "true" ]; then if [ "${ARTIFACT_EXISTS}" = "true" ]; then
echo "skip=true" >> "$GITHUB_OUTPUT" echo "skip=true" >> "$GITHUB_OUTPUT"
else else