-
Notifications
You must be signed in to change notification settings - Fork 195
79 lines (76 loc) · 2.68 KB
/
test_zfs_root_guide.yml
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
name: "Test installation guides"
on:
push:
branches:
- master
paths:
- 'docs/Getting Started/NixOS/Root on ZFS.rst'
- 'docs/Getting Started/RHEL-based distro/Root on ZFS.rst'
- 'docs/Getting Started/Alpine Linux/Root on ZFS.rst'
- 'docs/Getting Started/Arch Linux/Root on ZFS.rst'
- 'docs/Getting Started/Fedora/Root on ZFS.rst'
- 'docs/Getting Started/zfs_root_maintenance.rst'
pull_request:
paths:
- 'docs/Getting Started/NixOS/Root on ZFS.rst'
- 'docs/Getting Started/RHEL-based distro/Root on ZFS.rst'
- 'docs/Getting Started/Alpine Linux/Root on ZFS.rst'
- 'docs/Getting Started/Arch Linux/Root on ZFS.rst'
- 'docs/Getting Started/Fedora/Root on ZFS.rst'
- 'docs/Getting Started/zfs_root_maintenance.rst'
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install shellcheck
run: |
sudo apt install --yes shellcheck
- name: Run shellcheck on test entry point
run: |
sh -n ./scripts/zfs_root_guide_test.sh
shellcheck --check-sourced --enable=all --shell=dash --severity=style --format=tty \
./scripts/zfs_root_guide_test.sh
- name: Install pylit
run: |
set -vexuf
sudo apt-get update -y
sudo apt-get install -y python3-pip
sudo pip install pylit
- name: Install ZFS and partitioning tools
run: |
set -vexuf
sudo add-apt-repository --yes universe
sudo apt install --yes zfsutils-linux
sudo apt install --yes qemu-utils
sudo modprobe zfs
sudo apt install --yes git jq parted
sudo apt install --yes whois curl
sudo apt install --yes arch-install-scripts
- name: Test Alpine Linux guide
run: |
sudo ./scripts/zfs_root_guide_test.sh alpine
- name: Test Root on ZFS maintenance guide
run: |
sudo ./scripts/zfs_root_guide_test.sh maintenance
- name: Test Arch Linux guide
run: |
sudo ./scripts/zfs_root_guide_test.sh archlinux
- name: Test Fedora guide
run: |
sudo ./scripts/zfs_root_guide_test.sh fedora
- name: Test RHEL guide
run: |
sudo ./scripts/zfs_root_guide_test.sh rhel
- uses: cachix/install-nix-action@v20
with:
nix_path: nixpkgs=channel:nixos-unstable
- name: Test NixOS guide
run: |
sudo PATH="${PATH}" NIX_PATH="${NIX_PATH}" ./scripts/zfs_root_guide_test.sh nixos
- uses: actions/upload-artifact@v3
with:
name: installation-scripts
path: |
*.sh