Skip to content
Snippets Groups Projects
Commit f940abce authored by Wouter Deconinck's avatar Wouter Deconinck
Browse files

fix: external trigger with VERSION has priority

parent 9738cc30
No related branches found
No related tags found
1 merge request!660fix: external trigger with VERSION has priority
...@@ -33,6 +33,9 @@ variables: ...@@ -33,6 +33,9 @@ variables:
## Additional options for docker build (e.g. --no-cache) ## Additional options for docker build (e.g. --no-cache)
BUILD_OPTIONS: BUILD_OPTIONS:
## Version to be set by external trigger
VERSION:
## Internal tag used for the CI ## Internal tag used for the CI
INTERNAL_TAG: "pipeline-${CI_PIPELINE_ID}" INTERNAL_TAG: "pipeline-${CI_PIPELINE_ID}"
...@@ -101,7 +104,10 @@ version: ...@@ -101,7 +104,10 @@ version:
stage: config stage: config
script: script:
- | - |
if [ "x${CI_PIPELINE_SOURCE}" = "xmerge_request_event" ]; then if [ -n "${VERSION}" ]; then
# external trigger with specified version
EXPORT_TAG="${VERSION}"
elif [ "x${CI_PIPELINE_SOURCE}" = "xmerge_request_event" ]; then
VERSION="unstable-mr-${CI_MERGE_REQUEST_PROJECT_ID}-${CI_MERGE_REQUEST_IID}" VERSION="unstable-mr-${CI_MERGE_REQUEST_PROJECT_ID}-${CI_MERGE_REQUEST_IID}"
NIGHTLY_TAG="${VERSION}-nightly" NIGHTLY_TAG="${VERSION}-nightly"
EXPORT_TAG="${VERSION}" EXPORT_TAG="${VERSION}"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment