mirror of
https://git.proxmox.com/git/mirror_zfs
synced 2025-04-28 13:20:02 +00:00

Add a new 'zfs-qemu-packages' GH workflow for manually building RPMs and test installing ZFS RPMs from a yum repo. The workflow has a dropdown menu in the Github runners tab with two options: Build RPMs - Build release RPMs and tarballs and put them into an artifact ZIP file. The directory structure used in the ZIP file mirrors the ZFS yum repo. Test repo - Test install the ZFS RPMs from the ZFS repo. On Almalinux, this will do a DKMS and KMOD test install from both the regular and testing repos. On Fedora, it will do a DKMS install from the regular repo. All test install results will be displayed in the Github runner Summary page. Note that the workflow provides an optional text box where you can specify the full URL to an alternate repo. If left blank, it will install from the default repo from the zfs-release RPM. Most developers will never need to use this workflow. It is intended to be used by the ZFS admins for building and testing releases. This commit also modularizes many of the runner scripts so they can be used by both the zfs-qemu and zfs-qemu-packages workflows. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Tino Reichardt <milky-zfs@mcmilk.de> Signed-off-by: Tony Hutter <hutter2@llnl.gov> Closes #17005
65 lines
2.1 KiB
YAML
65 lines
2.1 KiB
YAML
name: checkstyle
|
|
|
|
on:
|
|
push:
|
|
pull_request:
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
checkstyle:
|
|
runs-on: ubuntu-22.04
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
ref: ${{ github.event.pull_request.head.sha }}
|
|
- name: Install dependencies
|
|
run: |
|
|
# for x in lxd core20 snapd; do sudo snap remove $x; done
|
|
sudo apt-get purge -y snapd google-chrome-stable firefox
|
|
ONLY_DEPS=1 .github/workflows/scripts/qemu-3-deps-vm.sh ubuntu22
|
|
sudo apt-get install -y cppcheck devscripts mandoc pax-utils shellcheck
|
|
sudo python -m pipx install --quiet flake8
|
|
# confirm that the tools are installed
|
|
# the build system doesn't fail when they are not
|
|
checkbashisms --version
|
|
cppcheck --version
|
|
flake8 --version
|
|
scanelf --version
|
|
shellcheck --version
|
|
- name: Prepare
|
|
run: |
|
|
sed -i '/DEBUG_CFLAGS="-Werror"/s/^/#/' config/zfs-build.m4
|
|
./autogen.sh
|
|
- name: Configure
|
|
run: |
|
|
./configure
|
|
- name: Make
|
|
run: |
|
|
make -j$(nproc) --no-print-directory --silent
|
|
- name: Checkstyle
|
|
run: |
|
|
make -j$(nproc) --no-print-directory --silent checkstyle
|
|
- name: Lint
|
|
run: |
|
|
make -j$(nproc) --no-print-directory --silent lint
|
|
- name: CheckABI
|
|
id: CheckABI
|
|
run: |
|
|
docker run -v $PWD:/source ghcr.io/openzfs/libabigail make -j$(nproc) --no-print-directory --silent checkabi
|
|
- name: StoreABI
|
|
if: failure() && steps.CheckABI.outcome == 'failure'
|
|
run: |
|
|
docker run -v $PWD:/source ghcr.io/openzfs/libabigail make -j$(nproc) --no-print-directory --silent storeabi
|
|
- name: Prepare artifacts
|
|
if: failure() && steps.CheckABI.outcome == 'failure'
|
|
run: |
|
|
find -name *.abi | tar -cf abi_files.tar -T -
|
|
- uses: actions/upload-artifact@v4
|
|
if: failure() && steps.CheckABI.outcome == 'failure'
|
|
with:
|
|
name: New ABI files (use only if you're sure about interface changes)
|
|
path: abi_files.tar
|