forked from systemd/mkosi
-
Notifications
You must be signed in to change notification settings - Fork 0
/
action.yaml
48 lines (38 loc) · 1.08 KB
/
action.yaml
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: setup-mkosi
description: Install mkosi and all its dependencies
runs:
using: composite
steps:
- name: Cache dependencies
uses: actions/cache@v3
with:
path: build
key: ${{ runner.os }}-${{ hashFiles('action/setup-github-actions.sh') }}
- name: Dependencies
shell: bash
run: |
mkdir -p $BUILDDIR
sudo -E ${{ github.action_path }}/action/setup-github-actions.sh
sudo chown -R $USER: $BUILDDIR
sudo pacman-key --init
sudo pacman-key --populate archlinux
sudo tee /etc/systemd/network/80-vm-vt.network > /dev/null <<- EOF
[Match]
Name=vt-*
Driver=tun
[Network]
# Default to using a /28 prefix, giving up to 13 addresses per VM.
Address=0.0.0.0/28
LinkLocalAddressing=yes
DHCPServer=yes
IPMasquerade=yes
LLDP=yes
EmitLLDP=customer-bridge
IPv6PrefixDelegation=yes
EOF
sudo systemctl restart systemd-networkd
env:
BUILDDIR: build
- name: Install
shell: bash
run: sudo python3 -m pip install ${{ github.action_path }}