mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-09-01 23:25:38 +00:00
[9.18] new: ci: Add a check for defined but never used anchors in .gitlab-ci.yaml
If an new orphan anchor is (`.anchor: &anchor` with no corresponding `*anchor` elsewhere in the file) is introduced the CI job will. Depends on https://gitlab.isc.org/isc-projects/bind9-qa/-/merge_requests/101 (merge that first and then drop the `--branch` commit). Backport of MR !10654 Merge branch 'backport-stepan/ci-orphaned-anchors-9.18' into 'bind-9.18' See merge request isc-projects/bind9!10667
This commit is contained in:
@@ -94,11 +94,6 @@ stages:
|
|||||||
|
|
||||||
### Runner Tag Templates
|
### Runner Tag Templates
|
||||||
|
|
||||||
.libvirt-amd64: &libvirt_amd64
|
|
||||||
tags:
|
|
||||||
- libvirt
|
|
||||||
- amd64
|
|
||||||
|
|
||||||
# Autoscaling GitLab Runner on AWS EC2 (amd64)
|
# Autoscaling GitLab Runner on AWS EC2 (amd64)
|
||||||
|
|
||||||
.linux-amd64: &linux_amd64
|
.linux-amd64: &linux_amd64
|
||||||
@@ -246,10 +241,6 @@ stages:
|
|||||||
- if: '$CI_PIPELINE_SOURCE =~ /^(api|pipeline|schedule|trigger|web)$/'
|
- if: '$CI_PIPELINE_SOURCE =~ /^(api|pipeline|schedule|trigger|web)$/'
|
||||||
- if: '$CI_COMMIT_TAG != null'
|
- if: '$CI_COMMIT_TAG != null'
|
||||||
|
|
||||||
.api-pipelines-schedules-triggers-web-triggering-rules: &api_pipelines_schedules_triggers_web_triggering_rules
|
|
||||||
rules:
|
|
||||||
- if: '$CI_PIPELINE_SOURCE =~ /^(api|pipeline|schedule|trigger|web)$/'
|
|
||||||
|
|
||||||
.default-triggering-rules_list: &default_triggering_rules_list
|
.default-triggering-rules_list: &default_triggering_rules_list
|
||||||
- if: '$CI_PIPELINE_SOURCE =~ /^(api|merge_request_event|pipeline|schedule|trigger|web)$/'
|
- if: '$CI_PIPELINE_SOURCE =~ /^(api|merge_request_event|pipeline|schedule|trigger|web)$/'
|
||||||
- if: '$CI_COMMIT_TAG != null'
|
- if: '$CI_COMMIT_TAG != null'
|
||||||
@@ -372,8 +363,7 @@ stages:
|
|||||||
<<: *base_image
|
<<: *base_image
|
||||||
stage: performance
|
stage: performance
|
||||||
rules:
|
rules:
|
||||||
- &shotgun_rule_mr
|
- if: '$CI_MERGE_REQUEST_DIFF_BASE_SHA != null'
|
||||||
if: '$CI_MERGE_REQUEST_DIFF_BASE_SHA != null'
|
|
||||||
variables:
|
variables:
|
||||||
BASELINE: '$CI_MERGE_REQUEST_DIFF_BASE_SHA'
|
BASELINE: '$CI_MERGE_REQUEST_DIFF_BASE_SHA'
|
||||||
- &shotgun_rule_tag
|
- &shotgun_rule_tag
|
||||||
@@ -447,21 +437,6 @@ stages:
|
|||||||
reports:
|
reports:
|
||||||
junit: junit.xml
|
junit: junit.xml
|
||||||
|
|
||||||
.system_test_legacy: &system_test_legacy
|
|
||||||
script:
|
|
||||||
- cd bin/tests/system
|
|
||||||
- find . -maxdepth 2 -mindepth 2 -type f -name "tests.sh" | cut -d/ -f2 | xargs -n 1 -P ${TEST_PARALLEL_JOBS:-1} sh legacy.run.sh
|
|
||||||
- if git rev-parse > /dev/null 2>&1; then ( ! grep "^I:.*:file.*not removed$" *.log ); fi
|
|
||||||
- '( ! grep -F "grep: warning:" *.log )'
|
|
||||||
after_script:
|
|
||||||
- test -d bind-* && cd bind-*
|
|
||||||
- REALSOURCEDIR="$PWD"
|
|
||||||
- test -n "${OUT_OF_TREE_WORKSPACE}" && cd "${OUT_OF_TREE_WORKSPACE}"
|
|
||||||
- find bin/tests/system -name "*dig.*" | xargs grep "error" || true
|
|
||||||
- *find_python
|
|
||||||
- >
|
|
||||||
"$PYTHON" "$REALSOURCEDIR"/bin/tests/convert-trs-to-junit.py . > "$CI_PROJECT_DIR"/junit.xml
|
|
||||||
|
|
||||||
.system_test_make_check: &system_test_make_check_job
|
.system_test_make_check: &system_test_make_check_job
|
||||||
<<: *system_test_job
|
<<: *system_test_job
|
||||||
# This script needs to: 1) fail if the system tests fail, 2) fail if
|
# This script needs to: 1) fail if the system tests fail, 2) fail if
|
||||||
@@ -594,7 +569,6 @@ vulture:
|
|||||||
- vulture --exclude "*/ans*/ans.py,conftest.py,get_algorithms.py,isctest" --ignore-names "pytestmark" bin/tests/system/
|
- vulture --exclude "*/ans*/ans.py,conftest.py,get_algorithms.py,isctest" --ignore-names "pytestmark" bin/tests/system/
|
||||||
|
|
||||||
ci-variables:
|
ci-variables:
|
||||||
stage: precheck
|
|
||||||
<<: *precheck_job
|
<<: *precheck_job
|
||||||
script:
|
script:
|
||||||
- export BIND_BASELINE_BRANCH="$(sed -n -E "s|^m4_define\(\[bind_VERSION_MINOR\], ([0-9]+)\)dnl$|\1|p" configure.ac)"
|
- export BIND_BASELINE_BRANCH="$(sed -n -E "s|^m4_define\(\[bind_VERSION_MINOR\], ([0-9]+)\)dnl$|\1|p" configure.ac)"
|
||||||
@@ -610,6 +584,16 @@ ci-variables:
|
|||||||
reports:
|
reports:
|
||||||
dotenv: ci_vars.env
|
dotenv: ci_vars.env
|
||||||
|
|
||||||
|
ci-orphaned-anchors:
|
||||||
|
<<: *precheck_job
|
||||||
|
script:
|
||||||
|
- git clone --depth 1 https://gitlab.isc.org/isc-projects/bind9-qa.git
|
||||||
|
- bind9-qa/ci-orphaned-anchors/check-orphaned-anchors-ci.py .gitlab-ci.yml
|
||||||
|
needs: []
|
||||||
|
rules:
|
||||||
|
- changes:
|
||||||
|
- .gitlab-ci.yml
|
||||||
|
|
||||||
clang-format:
|
clang-format:
|
||||||
<<: *precheck_job
|
<<: *precheck_job
|
||||||
needs: []
|
needs: []
|
||||||
@@ -1662,9 +1646,6 @@ shotgun:doh-get:
|
|||||||
SHOTGUN_EVAL_THRESHOLD_LATENCY_PCTL_MAX: 0.4 # bump from the default due to increased tail-end jitter
|
SHOTGUN_EVAL_THRESHOLD_LATENCY_PCTL_MAX: 0.4 # bump from the default due to increased tail-end jitter
|
||||||
rules: *shotgun_rules_manual_mr
|
rules: *shotgun_rules_manual_mr
|
||||||
|
|
||||||
.stress-test: &stress_test
|
|
||||||
stage: performance
|
|
||||||
|
|
||||||
generate-stress-test-configs:
|
generate-stress-test-configs:
|
||||||
<<: *base_image
|
<<: *base_image
|
||||||
<<: *default_triggering_rules
|
<<: *default_triggering_rules
|
||||||
|
Reference in New Issue
Block a user