mirror of
https://github.com/prometheus/prometheus.git
synced 2026-05-28 04:02:21 -04:00
Merge pull request #18063 from roidelapluie/roidelapluie/actuallyold
Some checks are pending
buf.build / lint and publish (push) Waiting to run
CI / Go tests (push) Waiting to run
CI / More Go tests (push) Waiting to run
CI / Go tests with previous Go version (push) Waiting to run
CI / UI tests (push) Waiting to run
CI / Go tests on Windows (push) Waiting to run
CI / Mixins tests (push) Waiting to run
CI / Build Prometheus for common architectures (push) Waiting to run
CI / Build Prometheus for all architectures (push) Waiting to run
CI / Report status of build Prometheus for all architectures (push) Blocked by required conditions
CI / Check generated parser (push) Waiting to run
CI / golangci-lint (push) Waiting to run
CI / fuzzing (push) Waiting to run
CI / codeql (push) Waiting to run
CI / Publish main branch artifacts (push) Blocked by required conditions
CI / Publish release artefacts (push) Blocked by required conditions
CI / Publish UI on npm Registry (push) Blocked by required conditions
Scorecards supply-chain security / Scorecards analysis (push) Waiting to run
Some checks are pending
buf.build / lint and publish (push) Waiting to run
CI / Go tests (push) Waiting to run
CI / More Go tests (push) Waiting to run
CI / Go tests with previous Go version (push) Waiting to run
CI / UI tests (push) Waiting to run
CI / Go tests on Windows (push) Waiting to run
CI / Mixins tests (push) Waiting to run
CI / Build Prometheus for common architectures (push) Waiting to run
CI / Build Prometheus for all architectures (push) Waiting to run
CI / Report status of build Prometheus for all architectures (push) Blocked by required conditions
CI / Check generated parser (push) Waiting to run
CI / golangci-lint (push) Waiting to run
CI / fuzzing (push) Waiting to run
CI / codeql (push) Waiting to run
CI / Publish main branch artifacts (push) Blocked by required conditions
CI / Publish release artefacts (push) Blocked by required conditions
CI / Publish UI on npm Registry (push) Blocked by required conditions
Scorecards supply-chain security / Scorecards analysis (push) Waiting to run
chore: Check that previous go version check actually uses previous go version
This commit is contained in:
commit
19fd0b0b1d
1 changed files with 22 additions and 0 deletions
|
|
@ -47,3 +47,25 @@ if [[ "${matches}" -ne 1 ]]; then
|
|||
echo 'Not all go.mod/go.work files have matching go versions'
|
||||
exit 1
|
||||
fi
|
||||
|
||||
ci_workflow=".github/workflows/ci.yml"
|
||||
if [[ -f "${ci_workflow}" ]] && yq -e '.jobs.test_go_oldest' "${ci_workflow}" > /dev/null 2>&1; then
|
||||
echo "Checking CI workflow test_go_oldest uses N-1 Go version"
|
||||
|
||||
# Extract Go version from test_go_oldest job.
|
||||
get_test_go_oldest_version() {
|
||||
yq '.jobs.test_go_oldest.container.image' "${ci_workflow}" \
|
||||
| grep -oP 'golang-builder:1\.\K[0-9]+'
|
||||
}
|
||||
|
||||
test_go_oldest_version="$(get_test_go_oldest_version)"
|
||||
if [[ -z "${test_go_oldest_version}" || "${test_go_oldest_version}" -le 0 ]]; then
|
||||
echo "Error: Could not extract Go version from test_go_oldest job in ${ci_workflow}"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ "${test_go_oldest_version}" -ne "${supported_version}" ]]; then
|
||||
echo "Error: test_go_oldest uses Go 1.${test_go_oldest_version}, but should use Go 1.${supported_version} (oldest supported version)"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
|
|
|||
Loading…
Reference in a new issue