Compare commits

...

1 Commits

Author SHA1 Message Date
Petr Špaček
5f0d5d9613 Trigger Shotgun pipelines using multi-project pipeline mechanism
In theory this change should be no-op, but in practice it is a
workaround for https://gitlab.com/gitlab-org/gitlab/-/issues/355590
2024-04-04 18:22:28 +02:00

View File

@@ -346,21 +346,15 @@ stages:
- awk '/^=+ ERRORS =+/{flag=1;next}/^=+.*=+$/{flag=0}flag' bin/tests/system/pytest.out.txt || true
.shotgun: &shotgun_job
<<: *base_image
<<: *api_pipelines_schedules_tags_triggers_web_triggering_rules
stage: performance
script:
- if [ -z "$CI_COMMIT_TAG" ]; then export SHOTGUN_ROUNDS=1; else export SHOTGUN_ROUNDS=3; fi
- PIPELINE_ID=$(curl -s -X POST --fail
-F "token=$CI_JOB_TOKEN"
-F ref=main
-F "variables[SHOTGUN_TEST_VERSION]=['$CI_COMMIT_REF_NAME', '$BIND_BASELINE_VERSION']"
-F "variables[SHOTGUN_DURATION]=300"
-F "variables[SHOTGUN_ROUNDS]=$SHOTGUN_ROUNDS"
-F "variables[SHOTGUN_TRAFFIC_MULTIPLIER]=$SHOTGUN_TRAFFIC_MULTIPLIER"
-F "variables[SHOTGUN_SCENARIO]=$SHOTGUN_SCENARIO"
https://gitlab.isc.org/api/v4/projects/188/trigger/pipeline | jq .id)
- util/ci-wait-shotgun.py $PIPELINE_ID
trigger:
project: isc-projects/bind9-shotgun-ci
branch: main
strategy: depend
variables:
SHOTGUN_TEST_VERSION: "['$CI_COMMIT_REF_NAME', '$BIND_BASELINE_VERSION']"
SHOTGUN_DURATION: 300
needs:
- job: ci-variables
artifacts: true
@@ -551,6 +545,7 @@ ci-variables:
- if [ "$(sed -n -E "s|^m4_define\(\[bind_VERSION_PATCH\], ([0-9]+)\)dnl$|\1|p" configure.ac)" = "0" ]; then export BIND_BASELINE_BRANCH=$((BIND_BASELINE_BRANCH - 1 - (BIND_BASELINE_BRANCH % 2))); fi
- BIND_BASELINE_VERSION="$(curl -s "https://gitlab.isc.org/api/v4/projects/1/repository/tags?search=^v9.${BIND_BASELINE_BRANCH}&order_by=version" | jq -r ".[0].name")"
- echo "BIND_BASELINE_VERSION=$BIND_BASELINE_VERSION" >> ci_vars.env
- if [ -z "$CI_COMMIT_TAG" ]; then echo SHOTGUN_ROUNDS=1; else export SHOTGUN_ROUNDS=3; fi >> ci_vars.env
needs:
- job: autoreconf
artifacts: true
@@ -1634,26 +1629,22 @@ respdiff-long-third-party:
# allow re-use of the built container image. Otherwise, the jobs would do the
# same builds in parallel rather than re-use the already built image.
shotgun:udp:
<<: *shotgun_job
extends: .shotgun
variables:
SHOTGUN_SCENARIO: udp
SHOTGUN_TRAFFIC_MULTIPLIER: 15
shotgun:tcp:
<<: *shotgun_job
extends: .shotgun
variables:
SHOTGUN_SCENARIO: tcp
SHOTGUN_TRAFFIC_MULTIPLIER: 6
when: delayed
start_in: 5 minutes
shotgun:dot:
<<: *shotgun_job
extends: .shotgun
variables:
SHOTGUN_SCENARIO: dot
SHOTGUN_TRAFFIC_MULTIPLIER: 3
when: delayed
start_in: 5 minutes
# Parallel build in the "make" step is avoided since multiple jobs can be
# executed concurrently on the same runner. This may present problems when one