Skip to content

Commit 68e7373

Browse files
committed
ci: add more images
1. Replace ubuntu 22.04 with 24.04 2. Add debian trixie (13, "stable"). 3. Add fedora. Signed-off-by: Kir Kolyshkin <[email protected]>
1 parent 6736c99 commit 68e7373

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

.github/workflows/containers.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
strategy:
1818
fail-fast: false
1919
matrix:
20-
baseimage: ['debian:bullseye', 'ubuntu:20.04', 'ubuntu:22.04']
20+
baseimage: ['debian:bullseye', 'debian:trixie', 'ubuntu:20.04', 'ubuntu:24.04', 'fedora']
2121
go: [1.23, 1.24]
2222
steps:
2323
- uses: actions/checkout@v4

scripts/ci-runner.sh

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,14 @@ function run_in_ct {
3939
set -x
4040
docker pull "$image"
4141
docker run -i --privileged --cidfile="$cidfile" "$image" /bin/bash -e -x << EOF
42-
export DEBIAN_FRONTEND=noninteractive
43-
apt-get -qq update
44-
apt-get -qq install -y -o Dpkg::Use-Pty=0 \
42+
if dpkg --version; then
43+
export DEBIAN_FRONTEND=noninteractive
44+
apt-get -qq update
45+
apt-get -qq install -y -o Dpkg::Use-Pty=0 \
4546
sudo build-essential curl git dbus libsystemd-dev libpam-systemd systemd-container
47+
else # Assuming Fedora
48+
dnf install -qy sudo curl gcc git dbus systemd-devel systemd-container
49+
fi
4650
# Fixup git.
4751
git config --global --add safe.directory /src
4852
# Install Go.
@@ -57,7 +61,7 @@ EOF
5761
docker rm -f "$cid"
5862

5963
echo "Starting a container with systemd..."
60-
docker run --shm-size=2gb -d --cidfile="$cidfile" --privileged -v "${PWD}:/src" "$name" /bin/systemd --system
64+
docker run --shm-size=2gb -d --cidfile="$cidfile" --privileged -v "${PWD}:/src" "$name" /sbin/init --system
6165
cid=$(cat "$cidfile")
6266
rm -f "$cidfile"
6367
docker exec --privileged "$cid" /bin/bash -e -c 'cd /src; ./scripts/ci-runner.sh build_tests'

0 commit comments

Comments
 (0)