From 02b02de1b216b504aabd09377dabffd5e486b0d5 Mon Sep 17 00:00:00 2001 From: Duarte Santos Date: Sun, 23 Aug 2026 21:31:31 +0200 Subject: [PATCH] CI: PUBLISH_LATEST auch aus per API gestarteten Pipelines Die Regel pruefte nur auf source == web. Ueber die API gestartet ist die Quelle "api", der Job lief dann nur zufaellig mit - naemlich ueber die Default-Branch-Regel, waehrend das Script die Variable trotzdem sah. --- .gitlab-ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 147fee6..83e0389 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -116,8 +116,8 @@ test:mcp: # through QEMU on the shared runners and costs several times the minutes — a self-hoster # on a Pi pulls `latest`, which always comes from a release and is always multi-arch. # -# Third way in: start a pipeline by hand (Build -> Pipelines -> New pipeline) with the -# variable PUBLISH_LATEST set to anything. That builds exactly like a tag would — multi-arch, +# Third way in: start a pipeline by hand (Build -> Pipelines -> New pipeline, or the API) +# with the variable PUBLISH_LATEST set to anything. That builds exactly like a tag would — multi-arch, # `latest` and the version out of frontend/package.json — without cutting a release. It is # there for the rebuild-without-a-code-change case: a base image picking up a CVE fix, where # the published `latest` needs to move but the app did not change. @@ -193,7 +193,7 @@ build:images: - if: $CI_PIPELINE_SOURCE == "schedule" when: never - if: $CI_COMMIT_TAG =~ /^v\d+\.\d+\.\d+$/ - - if: $CI_PIPELINE_SOURCE == "web" && $PUBLISH_LATEST + - if: ($CI_PIPELINE_SOURCE == "web" || $CI_PIPELINE_SOURCE == "api") && $PUBLISH_LATEST - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH - if: $CI_PIPELINE_SOURCE == "merge_request_event" when: manual