Skip to content

Commit 128647a

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

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,9 +39,13 @@ 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 sudo build-essential curl git dbus libsystemd-dev libpam-systemd systemd-container
42+
if dpkg --version; then
43+
export DEBIAN_FRONTEND=noninteractive
44+
apt-get -qq update
45+
apt-get -qq install -y sudo build-essential curl git dbus libsystemd-dev libpam-systemd systemd-container
46+
else # Assuming Fedora
47+
dnf install -y sudo curl gcc git dbus systemd-devel systemd-container
48+
fi
4549
# Fixup git.
4650
git config --global --add safe.directory /src
4751
# Install Go.
@@ -56,7 +60,7 @@ EOF
5660
docker rm -f "$cid"
5761

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

0 commit comments

Comments
 (0)