mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2024-11-17 18:11:00 +03:00
08cd071735
It turns out the ax_python_devel.m4 version check assumes that ("3.X+1.0" >= "3.X.0") is True in Python, which is not when X+1 is 10 or above and X is not. (Also presumably X+1=100 and ...) So let's remake the check to behave consistently, using the "packaging" or (if absent) the "distlib" modules. (Also, update the Github workflows to use the new packages.) Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: John Kennedy <john.kennedy@delphix.com> Signed-off-by: Rich Ercolani <rincebrain@gmail.com> Closes: #12073
68 lines
2.4 KiB
YAML
68 lines
2.4 KiB
YAML
name: zfs-tests-sanity
|
|
|
|
on:
|
|
push:
|
|
pull_request:
|
|
|
|
jobs:
|
|
tests:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
with:
|
|
ref: ${{ github.event.pull_request.head.sha }}
|
|
- name: Install dependencies
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install --yes -qq build-essential autoconf libtool gdb lcov \
|
|
git alien fakeroot wget curl bc fio acl \
|
|
sysstat mdadm lsscsi parted gdebi attr dbench watchdog ksh \
|
|
nfs-kernel-server samba rng-tools xz-utils \
|
|
zlib1g-dev uuid-dev libblkid-dev libselinux-dev \
|
|
xfslibs-dev libattr1-dev libacl1-dev libudev-dev libdevmapper-dev \
|
|
libssl-dev libffi-dev libaio-dev libelf-dev libmount-dev \
|
|
libpam0g-dev pamtester python-dev python-setuptools python-cffi \
|
|
python-packaging python3 python3-dev python3-setuptools python3-cffi \
|
|
python3-packaging libcurl4-openssl-dev
|
|
- name: Autogen.sh
|
|
run: |
|
|
sh autogen.sh
|
|
- name: Configure
|
|
run: |
|
|
./configure --enable-debug --enable-debuginfo
|
|
- name: Make
|
|
run: |
|
|
make --no-print-directory -s pkg-utils pkg-kmod
|
|
- name: Install
|
|
run: |
|
|
sudo dpkg -i *.deb
|
|
# Update order of directories to search for modules, otherwise
|
|
# Ubuntu will load kernel-shipped ones.
|
|
sudo sed -i.bak 's/updates/extra updates/' /etc/depmod.d/ubuntu.conf
|
|
sudo depmod
|
|
sudo modprobe zfs
|
|
# Workaround to provide additional free space for testing.
|
|
# https://github.com/actions/virtual-environments/issues/2840
|
|
sudo rm -rf /usr/share/dotnet
|
|
sudo rm -rf /opt/ghc
|
|
sudo rm -rf "/usr/local/share/boost"
|
|
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
|
|
- name: Tests
|
|
run: |
|
|
/usr/share/zfs/zfs-tests.sh -v -s 3G -r sanity
|
|
- name: Prepare artifacts
|
|
if: failure()
|
|
run: |
|
|
RESULTS_PATH=$(readlink -f /var/tmp/test_results/current)
|
|
sudo dmesg > $RESULTS_PATH/dmesg
|
|
sudo cp /var/log/syslog $RESULTS_PATH/
|
|
sudo chmod +r $RESULTS_PATH/*
|
|
# Replace ':' in dir names, actions/upload-artifact doesn't support it
|
|
for f in $(find $RESULTS_PATH -name '*:*'); do mv "$f" "${f//:/__}"; done
|
|
- uses: actions/upload-artifact@v2
|
|
if: failure()
|
|
with:
|
|
name: Test logs
|
|
path: /var/tmp/test_results/20*/
|
|
if-no-files-found: ignore
|