From 3f56557d55aafddad3ef4aea15470c5a92946edf Mon Sep 17 00:00:00 2001 From: Michal Nowak Date: Wed, 17 Mar 2021 17:19:47 +0100 Subject: [PATCH 1/4] Add FreeBSD 13.0 (cherry picked from commit 0714fe6f40456bc6cfb6797f39d592a718670db6) --- .gitlab-ci.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index a5e13748c2..e4e1a41634 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -178,6 +178,10 @@ stages: image: "freebsd-12.2-x86_64" <<: *libvirt_amd64 +.freebsd-13-amd64: &freebsd_13_amd64_image + image: "freebsd-13.0-x86_64" + <<: *libvirt_amd64 + .openbsd-amd64: &openbsd_amd64_image image: "openbsd-6.9-x86_64" <<: *libvirt_amd64 @@ -1236,6 +1240,33 @@ unit:clang:freebsd12:amd64: - job: clang:freebsd12:amd64 artifacts: true +# Jobs for Clang builds on FreeBSD 13 (amd64) + +clang:freebsd13:amd64: + variables: + CFLAGS: "${CFLAGS_COMMON}" + EXTRA_CONFIGURE: "${WITH_READLINE_LIBEDIT}" + USER: gitlab-runner + <<: *freebsd_13_amd64_image + <<: *build_job + +system:clang:freebsd13:amd64: + <<: *freebsd_13_amd64_image + <<: *system_test_job + variables: + USER: gitlab-runner + TEST_PARALLEL_JOBS: 4 + needs: + - job: clang:freebsd13:amd64 + artifacts: true + +unit:clang:freebsd13:amd64: + <<: *freebsd_13_amd64_image + <<: *unit_test_job + needs: + - job: clang:freebsd13:amd64 + artifacts: true + # Jobs for Clang builds on OpenBSD (amd64) clang:openbsd:amd64: From 7319cc786a270fde6807c87cfcdfab21b46bd934 Mon Sep 17 00:00:00 2001 From: Michal Nowak Date: Thu, 20 May 2021 10:56:12 +0200 Subject: [PATCH 2/4] Create an anchor for schedules, tags, and web rules It's a common pattern to spawn CI jobs only for pipelines triggered by schedules, tags, and web. There should be an anchor so that the rules are not repeated. (cherry picked from commit e4f88c359c85c2f084901289e3406c80674368ff) --- .gitlab-ci.yml | 36 ++++++++++++------------------------ 1 file changed, 12 insertions(+), 24 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index e4e1a41634..ec791ee6f2 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -204,6 +204,12 @@ stages: - main@isc-projects/bind9 - /^v9_[1-9][0-9]$/@isc-projects/bind9 +.schedules-tags-web-triggering-rules: &schedules_tags_web_triggering_rules + only: + - schedules + - tags + - web + .precheck: &precheck_job <<: *default_triggering_rules <<: *base_image @@ -335,6 +341,7 @@ stages: --output kyua_html > /dev/null .windows_system_test: &windows_system_test_job + <<: *schedules_tags_web_triggering_rules stage: system script: - 'Push-Location bin/tests/system' @@ -350,10 +357,6 @@ stages: untracked: true expire_in: "1 day" when: on_failure - only: - - schedules - - tags - - web .unit_test_common: &unit_test_common <<: *default_triggering_rules @@ -513,6 +516,7 @@ pylint: tarball-create: stage: precheck <<: *base_image + <<: *schedules_tags_web_triggering_rules script: - source version - export BIND_DIRECTORY="bind-${MAJORVER}.${MINORVER}.${PATCHVER}${RELEASETYPE}${RELEASEVER}" @@ -524,10 +528,6 @@ tarball-create: artifacts: paths: - bind-*.tar.${TARBALL_EXTENSION} - only: - - schedules - - tags - - web # Jobs for doc builds on Debian Sid (amd64) @@ -814,6 +814,7 @@ gcc:tarball: RUN_MAKE_INSTALL: 1 <<: *base_image <<: *build_job + <<: *schedules_tags_web_triggering_rules before_script: - tar --extract --file bind-*.tar.${TARBALL_EXTENSION} - rm -f bind-*.tar.${TARBALL_EXTENSION} @@ -821,37 +822,27 @@ gcc:tarball: needs: - job: tarball-create artifacts: true - only: - - schedules - - tags - - web system:gcc:tarball: <<: *base_image <<: *system_test_job + <<: *schedules_tags_web_triggering_rules before_script: - cd bind-* - *setup_interfaces needs: - job: gcc:tarball artifacts: true - only: - - schedules - - tags - - web unit:gcc:tarball: <<: *base_image <<: *unit_test_job + <<: *schedules_tags_web_triggering_rules before_script: - cd bind-* needs: - job: gcc:tarball artifacts: true - only: - - schedules - - tags - - web # Jobs for debug GCC builds on openSUSE Tumbleweed (amd64) @@ -1334,12 +1325,9 @@ system:msvc:windows:amd64: msvc-debug:windows:amd64: <<: *windows_server_2016_amd64_image <<: *windows_build_job + <<: *schedules_tags_web_triggering_rules variables: VSCONF: Debug - only: - - schedules - - tags - - web system:msvc-debug:windows:amd64: <<: *windows_server_2016_amd64_image From a3bd8d36d8ccd4cfcdd89410a482298a9a70361d Mon Sep 17 00:00:00 2001 From: Michal Nowak Date: Thu, 20 May 2021 11:06:48 +0200 Subject: [PATCH 3/4] Do not spawn FreeBSD 11 CI jobs in merge requests (cherry picked from commit 70eccd29526cbfab7b3032072dddbe37201ed254) --- .gitlab-ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index ec791ee6f2..ae6c98ec6e 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1187,10 +1187,12 @@ clang:freebsd11:amd64: USER: gitlab-runner <<: *freebsd_11_amd64_image <<: *build_job + <<: *schedules_tags_web_triggering_rules system:clang:freebsd11:amd64: <<: *freebsd_11_amd64_image <<: *system_test_job + <<: *schedules_tags_web_triggering_rules variables: USER: gitlab-runner TEST_PARALLEL_JOBS: 4 @@ -1201,6 +1203,7 @@ system:clang:freebsd11:amd64: unit:clang:freebsd11:amd64: <<: *freebsd_11_amd64_image <<: *unit_test_job + <<: *schedules_tags_web_triggering_rules needs: - job: clang:freebsd11:amd64 artifacts: true From 25b8add3823d1b6ff2d2fa61c3df5fa993129ab5 Mon Sep 17 00:00:00 2001 From: Michal Nowak Date: Thu, 20 May 2021 18:00:28 +0200 Subject: [PATCH 4/4] Run gcc:tarball CI job for merge requests Running gcc:tarball CI job for merge requests is consistent with how we run gcc:out-of-tree CI job and should help identify problems with the build system during the review process, not once merged during daily runs. For the sake of time, unit and system tests associated with the gcc:tarball CI job are excluded from merge requests. Also, make sure that the tarball-create CI job includes the default_triggering_rules anchor (as it is on the main branch), otherwise adding the gcc:tarball CI job to merge request-triggered pipeline fails with: Found errors in your .gitlab-ci.yml: 'gcc:tarball' job needs 'tarball-create' job but it was not added to the pipeline (cherry picked from commit 83617cea9a7ac4b877b0874d041d21d80eb36fac) --- .gitlab-ci.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index ae6c98ec6e..4657948aab 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -516,7 +516,7 @@ pylint: tarball-create: stage: precheck <<: *base_image - <<: *schedules_tags_web_triggering_rules + <<: *default_triggering_rules script: - source version - export BIND_DIRECTORY="bind-${MAJORVER}.${MINORVER}.${PATCHVER}${RELEASETYPE}${RELEASEVER}" @@ -814,7 +814,6 @@ gcc:tarball: RUN_MAKE_INSTALL: 1 <<: *base_image <<: *build_job - <<: *schedules_tags_web_triggering_rules before_script: - tar --extract --file bind-*.tar.${TARBALL_EXTENSION} - rm -f bind-*.tar.${TARBALL_EXTENSION}