-
Notifications
You must be signed in to change notification settings - Fork 81
48 lines (38 loc) · 1.37 KB
/
run.yml
File metadata and controls
48 lines (38 loc) · 1.37 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Run
on:
push:
branches:
- main
pull_request:
jobs:
run:
runs-on: ubuntu-latest
steps:
### DEPENDENCIES ###
# Hard turn-off interactive mode
- run: echo 'debconf debconf/frontend select Noninteractive' | sudo debconf-set-selections
# Install dependencies
- run: sudo apt-get update
- run: |
sudo apt-get install --yes --no-install-recommends \
git qemu-kvm udev iproute2 busybox-static coreutils \
python3-requests python3-argcomplete libvirt-clients kbd kmod \
file rsync zstd virtiofsd
### END DEPENDENCIES ###
# Checkout git repository
- uses: actions/checkout@v4
# Run `uname -r` using a vanilla v6.6 kernel
- run: ./vng -r v6.6 -v -- uname -r
# Build virtme-ng-init
- run: make
# Setup KVM support
- name: "KVM support"
run: |
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
sudo udevadm control --reload-rules
sudo udevadm trigger --name-match=kvm
# Re-run with KVM support and virtme-ng-init
- name: "Check KVM support"
run: |
clocksource="/sys/devices/system/clocksource/clocksource0/current_clocksource"
[ "$(./vng -r v6.6 -v -- cat "${clocksource}")" = "kvm-clock" ]