Skip to content

Commit f51b6a2

Browse files
parameterise staging CI job for ubuntu version
1 parent afdbb6d commit f51b6a2

File tree

4 files changed

+10
-7
lines changed

4 files changed

+10
-7
lines changed

.github/workflows/staging.yml

+4
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,13 @@ on:
99

1010
jobs:
1111
staging:
12+
strategy:
13+
matrix:
14+
ubuntu_version: ["focal", "noble"]
1215
runs-on: ubuntu-latest
1316
env:
1417
GOOGLE_CREDENTIALS: ${{ secrets.GOOGLE_CREDENTIALS }}
18+
UBUNTU_VERSION: ${{ matrix.ubuntu_version }}
1519
steps:
1620
- uses: actions/checkout@v4
1721
- name: Run staging tests on GCE

devops/gce-nested/ci-env.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,15 @@ TOPLEVEL="$(git rev-parse --show-toplevel)"
1313
export TOPLEVEL
1414
GCE_CREDS_FILE="${TOPLEVEL}/.gce.creds"
1515
export GCE_CREDS_FILE
16+
export UBUNTU_VERSION="${UBUNTU_VERSION:-focal}"
1617
export BUILD_NUM="${GITHUB_RUN_ID}-${GITHUB_RUN_ATTEMPT}"
1718
export PROJECT_ID="securedrop-ci"
1819
export JOB_NAME="sd-ci-nested"
1920
export GCLOUD_MACHINE_TYPE="c2-standard-8"
2021
export GCLOUD_CONTAINER_VER
2122
export CLOUDSDK_COMPUTE_ZONE="us-west1-c"
2223
export EPHEMERAL_DIRECTORY="/tmp/gce-nested"
23-
export FULL_JOB_ID="${JOB_NAME}-${BUILD_NUM}"
24+
export FULL_JOB_ID="${JOB_NAME}-${UBUNTU_VERSION}-${BUILD_NUM}"
2425
export SSH_USER_NAME=sdci
2526
export SSH_PRIVKEY="${EPHEMERAL_DIRECTORY}/gce"
2627
export SSH_PUBKEY="${SSH_PRIVKEY}.pub"

devops/gce-nested/ci-go.sh

-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@ set -e
1212
set -u
1313
set -o pipefail
1414

15-
export BASE_OS="${BASE_OS:-focal}"
16-
1715
./devops/gce-nested/gce-start.sh
1816
./devops/gce-nested/gce-runner.sh
1917
./devops/gce-nested/gce-stop.sh

devops/gce-nested/gce-runner.sh

+4-4
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# for storage as artifacts on the build, so devs can review via web.
55
set -e
66
set -u
7-
BASE_OS="${BASE_OS:-focal}"
7+
UBUNTU_VERSION="${UBUNTU_VERSION:-focal}"
88

99

1010
TOPLEVEL="$(git rev-parse --show-toplevel)"
@@ -56,6 +56,6 @@ copy_securedrop_repo
5656
# so register a trap to ensure the fetch always runs.
5757
trap fetch_junit_test_results EXIT
5858

59-
ssh_gce "make build-debs-notest"
60-
ssh_gce "make build-debs-ossec-notest"
61-
ssh_gce "make staging"
59+
ssh_gce "UBUNTU_VERSION=\"${UBUNTU_VERSION}\" make build-debs-notest"
60+
ssh_gce "UBUNTU_VERSION=\"${UBUNTU_VERSION}\" make build-debs-ossec-notest"
61+
ssh_gce "UBUNTU_VERSION=\"${UBUNTU_VERSION}\" make staging"

0 commit comments

Comments
 (0)