Skip to content

Commit 255e554

Browse files
committed
ci: Use bootc-ubuntu-setup action to deduplicate workflow setup
The bootc-ubuntu-setup action was recently added and provides consolidated setup for podman, just, libvirt, KVM permissions, and Rust caching. Both the build and integration-tests jobs were duplicating this setup code. Replace the duplicated setup steps with the shared action. The only additional dependency needed is go-md2man in the build job. Assisted-by: Claude Code (Sonnet 4.5) Signed-off-by: Colin Walters <walters@verbum.org>
1 parent d4db380 commit 255e554

1 file changed

Lines changed: 10 additions & 33 deletions

File tree

.github/workflows/main.yml

Lines changed: 10 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -18,19 +18,14 @@ jobs:
1818
runs-on: ubuntu-24.04
1919

2020
steps:
21-
- name: Install dependencies
22-
run: |
23-
sudo apt update
24-
sudo apt install -y just pkg-config go-md2man libvirt-daemon libvirt-clients qemu-kvm qemu-system qemu-utils virtiofsd
21+
- uses: actions/checkout@v4
2522

26-
- name: Install podman for heredoc support
27-
run: |
28-
set -eux
29-
echo 'deb [trusted=yes] https://ftp.debian.org/debian/ testing main' | sudo tee /etc/apt/sources.list.d/testing.list
30-
sudo apt update
31-
sudo apt install -y crun/testing podman/testing just
23+
- uses: ./.github/actions/bootc-ubuntu-setup
24+
with:
25+
libvirt: 'true'
3226

33-
- uses: actions/checkout@v4
27+
- name: Install additional dependencies
28+
run: sudo apt install -y go-md2man
3429

3530
- name: Extract image lists from Justfile
3631
run: |
@@ -42,9 +37,6 @@ jobs:
4237

4338
- uses: taiki-e/install-action@nextest
4439

45-
- name: Cache build artifacts
46-
uses: Swatinem/rust-cache@v2
47-
4840
- name: Build
4941
run: just validate && just build
5042

@@ -98,27 +90,12 @@ jobs:
9890
partition: [1, 2, 3, 4]
9991

10092
steps:
101-
- name: Install dependencies
102-
run: |
103-
sudo apt update
104-
sudo apt install -y just pkg-config go-md2man libvirt-daemon libvirt-clients qemu-kvm qemu-system qemu-utils virtiofsd
105-
106-
- name: Install podman for heredoc support
107-
run: |
108-
set -eux
109-
echo 'deb [trusted=yes] https://ftp.debian.org/debian/ testing main' | sudo tee /etc/apt/sources.list.d/testing.list
110-
sudo apt update
111-
sudo apt install -y crun/testing podman/testing just
112-
113-
- name: Enable KVM group perms
114-
run: |
115-
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
116-
sudo udevadm control --reload-rules
117-
sudo udevadm trigger --name-match=kvm
118-
ls -l /dev/kvm
119-
12093
- uses: actions/checkout@v4
12194

95+
- uses: ./.github/actions/bootc-ubuntu-setup
96+
with:
97+
libvirt: 'true'
98+
12299
- name: Extract image lists from Justfile
123100
run: |
124101
echo "PRIMARY_IMAGE=$(just --evaluate PRIMARY_IMAGE)" >> $GITHUB_ENV

0 commit comments

Comments
 (0)