Commit a7af6042 authored by Rémy Coutable's avatar Rémy Coutable

Fix the package-and-qa and review-build-cng jobs

By changing the `review-build-cng` job to be a `single-script-job`, the
repository content wasn't there, including the `*_VERSION` files, thus
leading to missing variables for components in the triggered pipeline.
Signed-off-by: default avatarRémy Coutable <remy@rymai.me>
parent d7a3f875
...@@ -120,9 +120,8 @@ stages: ...@@ -120,9 +120,8 @@ stages:
variables: &single-script-job-variables variables: &single-script-job-variables
GIT_STRATEGY: none GIT_STRATEGY: none
before_script: before_script:
# We need to download the script rather than clone the repo since the # We don't clone the repo by using GIT_STRATEGY: none and only download the
# package-and-qa job will not be able to run when the branch gets # single script we need here so it's much faster than cloning.
# deleted (when merging the MR).
- export SCRIPT_NAME="${SCRIPT_NAME:-$CI_JOB_NAME}" - export SCRIPT_NAME="${SCRIPT_NAME:-$CI_JOB_NAME}"
- apk add --update openssl - apk add --update openssl
- wget $CI_PROJECT_URL/raw/$CI_COMMIT_SHA/scripts/$SCRIPT_NAME - wget $CI_PROJECT_URL/raw/$CI_COMMIT_SHA/scripts/$SCRIPT_NAME
...@@ -228,20 +227,21 @@ stages: ...@@ -228,20 +227,21 @@ stages:
# Trigger a package build in omnibus-gitlab repository # Trigger a package build in omnibus-gitlab repository
# #
package-and-qa: package-and-qa:
<<: *single-script-job image: ruby:2.5-alpine
stage: test
before_script: []
dependencies: []
cache: {}
variables: variables:
<<: *single-script-job-variables GIT_DEPTH: "1"
API_TOKEN: "${GITLAB_BOT_MULTI_PROJECT_PIPELINE_POLLING_TOKEN}" API_TOKEN: "${GITLAB_BOT_MULTI_PROJECT_PIPELINE_POLLING_TOKEN}"
SCRIPT_NAME: trigger-build
retry: 0 retry: 0
script: script:
- gem install gitlab --no-document
- apk add --update openssl curl jq - apk add --update openssl curl jq
- wget $CI_PROJECT_URL/raw/$CI_COMMIT_SHA/scripts/review_apps/review-apps.sh - gem install gitlab --no-document
- chmod 755 review-apps.sh - source ./scripts/review_apps/review-apps.sh
- source ./review-apps.sh
- wait_for_job_to_be_done "gitlab:assets:compile" - wait_for_job_to_be_done "gitlab:assets:compile"
- ./$SCRIPT_NAME omnibus - ./scripts/trigger-build omnibus
when: manual when: manual
only: only:
- //@gitlab-org/gitlab-ce - //@gitlab-org/gitlab-ce
...@@ -951,20 +951,21 @@ no_ee_check: ...@@ -951,20 +951,21 @@ no_ee_check:
# GitLab Review apps # GitLab Review apps
review-build-cng: review-build-cng:
<<: *single-script-job
<<: *review-only <<: *review-only
image: ruby:2.5-alpine
stage: test
before_script: []
dependencies: []
cache: {}
variables: variables:
<<: *single-script-job-variables GIT_DEPTH: "1"
SCRIPT_NAME: trigger-build
API_TOKEN: "${GITLAB_BOT_MULTI_PROJECT_PIPELINE_POLLING_TOKEN}" API_TOKEN: "${GITLAB_BOT_MULTI_PROJECT_PIPELINE_POLLING_TOKEN}"
script: script:
- gem install gitlab --no-document
- apk add --update openssl curl jq - apk add --update openssl curl jq
- wget $CI_PROJECT_URL/raw/$CI_COMMIT_SHA/scripts/review_apps/review-apps.sh - gem install gitlab --no-document
- chmod 755 review-apps.sh - source ./scripts/review_apps/review-apps.sh
- source ./review-apps.sh
- wait_for_job_to_be_done "gitlab:assets:compile" - wait_for_job_to_be_done "gitlab:assets:compile"
- BUILD_TRIGGER_TOKEN=$REVIEW_APPS_BUILD_TRIGGER_TOKEN ./$SCRIPT_NAME cng - BUILD_TRIGGER_TOKEN=$REVIEW_APPS_BUILD_TRIGGER_TOKEN ./scripts/trigger-build cng
review-deploy: review-deploy:
<<: *review-base <<: *review-base
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment