Extract workflows dependencies
- Move build dependencies moved to `.github/workflows/build-dependencies.txt` shared among workflows. - Change `ubuntu-latest` -> `ubuntu-20.04` to avoid unexpected runner environment updates in `zloop` workflow. - Change `ubuntu-20.04` -> `ubuntu-latest` to track changes in runner environment in `checkstyle` workflow. - Kernel buffer is flushed before ZTS invocation to avoid storing the same data after each test case run. - `make` is invoked with consistent set of options to reduce clutter in logs. Reviewed-by: George Melikov <mail@gmelikov.ru> Signed-off-by: szubersk <szuberskidamian@gmail.com> Closes #13037
This commit is contained in:
parent
1dccfd7a38
commit
add15e9539
|
@ -0,0 +1,48 @@
|
||||||
|
acl
|
||||||
|
alien
|
||||||
|
attr
|
||||||
|
autoconf
|
||||||
|
bc
|
||||||
|
build-essential
|
||||||
|
curl
|
||||||
|
dbench
|
||||||
|
fakeroot
|
||||||
|
fio
|
||||||
|
gdb
|
||||||
|
gdebi
|
||||||
|
git
|
||||||
|
ksh
|
||||||
|
lcov
|
||||||
|
libacl1-dev
|
||||||
|
libaio-dev
|
||||||
|
libattr1-dev
|
||||||
|
libblkid-dev
|
||||||
|
libcurl4-openssl-dev
|
||||||
|
libdevmapper-dev
|
||||||
|
libelf-dev
|
||||||
|
libffi-dev
|
||||||
|
libmount-dev
|
||||||
|
libpam0g-dev
|
||||||
|
libselinux-dev
|
||||||
|
libssl-dev
|
||||||
|
libtool
|
||||||
|
libudev-dev
|
||||||
|
lsscsi
|
||||||
|
mdadm
|
||||||
|
nfs-kernel-server
|
||||||
|
pamtester
|
||||||
|
parted
|
||||||
|
python3
|
||||||
|
python3-cffi
|
||||||
|
python3-dev
|
||||||
|
python3-packaging
|
||||||
|
python3-setuptools
|
||||||
|
rng-tools
|
||||||
|
samba
|
||||||
|
sysstat
|
||||||
|
uuid-dev
|
||||||
|
watchdog
|
||||||
|
wget
|
||||||
|
xfslibs-dev
|
||||||
|
xz-utils
|
||||||
|
zlib1g-dev
|
|
@ -6,7 +6,7 @@ on:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
checkstyle:
|
checkstyle:
|
||||||
runs-on: ubuntu-20.04
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
|
@ -14,31 +14,37 @@ jobs:
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install --yes -qq build-essential autoconf libtool gawk alien fakeroot linux-headers-$(uname -r)
|
sudo xargs --arg-file=${{ github.workspace }}/.github/workflows/build-dependencies.txt apt-get install -qq
|
||||||
sudo apt-get install --yes -qq zlib1g-dev uuid-dev libattr1-dev libblkid-dev libselinux-dev libudev-dev libssl-dev python3 python3-dev python3-setuptools python3-cffi
|
sudo apt-get install -qq mandoc cppcheck pax-utils devscripts
|
||||||
# packages for tests
|
sudo python3 -m pip install --quiet flake8
|
||||||
sudo apt-get install --yes -qq parted lsscsi ksh attr acl nfs-kernel-server fio
|
sudo apt-get clean
|
||||||
sudo apt-get install --yes -qq mandoc cppcheck pax-utils devscripts
|
|
||||||
sudo -E pip --quiet install 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
|
- name: Prepare
|
||||||
run: |
|
run: |
|
||||||
sh ./autogen.sh
|
./autogen.sh
|
||||||
./configure
|
./configure
|
||||||
make -j$(nproc)
|
make -j$(nproc) --no-print-directory --silent
|
||||||
- name: Checkstyle
|
- name: Checkstyle
|
||||||
run: |
|
run: |
|
||||||
make checkstyle
|
make -j$(nproc) --no-print-directory --silent checkstyle
|
||||||
- name: Lint
|
- name: Lint
|
||||||
run: |
|
run: |
|
||||||
make lint
|
make -j$(nproc) --no-print-directory --silent lint
|
||||||
- name: CheckABI
|
- name: CheckABI
|
||||||
id: CheckABI
|
id: CheckABI
|
||||||
run: |
|
run: |
|
||||||
sudo docker run -v $(pwd):/source ghcr.io/openzfs/libabigail make checkabi
|
docker run -v $(pwd):/source ghcr.io/openzfs/libabigail make -j$(nproc) --no-print-directory --silent checkabi
|
||||||
- name: StoreABI
|
- name: StoreABI
|
||||||
if: failure() && steps.CheckABI.outcome == 'failure'
|
if: failure() && steps.CheckABI.outcome == 'failure'
|
||||||
run: |
|
run: |
|
||||||
sudo docker run -v $(pwd):/source ghcr.io/openzfs/libabigail make storeabi
|
docker run -v $(pwd):/source ghcr.io/openzfs/libabigail make -j$(nproc) --no-print-directory --silent storeabi
|
||||||
- name: Prepare artifacts
|
- name: Prepare artifacts
|
||||||
if: failure() && steps.CheckABI.outcome == 'failure'
|
if: failure() && steps.CheckABI.outcome == 'failure'
|
||||||
run: |
|
run: |
|
||||||
|
|
|
@ -18,24 +18,17 @@ jobs:
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install --yes -qq build-essential autoconf libtool gdb lcov \
|
xargs --arg-file=${{ github.workspace }}/.github/workflows/build-dependencies.txt sudo apt-get install -qq
|
||||||
git alien fakeroot wget curl bc fio acl \
|
sudo apt-get clean
|
||||||
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 libcurl4-openssl-dev \
|
|
||||||
python3 python3-dev python3-setuptools python3-cffi python3-packaging
|
|
||||||
- name: Autogen.sh
|
- name: Autogen.sh
|
||||||
run: |
|
run: |
|
||||||
sh autogen.sh
|
./autogen.sh
|
||||||
- name: Configure
|
- name: Configure
|
||||||
run: |
|
run: |
|
||||||
./configure --enable-debug --enable-debuginfo --enable-asan --enable-ubsan
|
./configure --enable-debug --enable-debuginfo --enable-asan --enable-ubsan
|
||||||
- name: Make
|
- name: Make
|
||||||
run: |
|
run: |
|
||||||
make --no-print-directory -s pkg-utils pkg-kmod
|
make -j$(nproc) --no-print-directory --silent pkg-utils pkg-kmod
|
||||||
- name: Install
|
- name: Install
|
||||||
run: |
|
run: |
|
||||||
sudo dpkg -i *.deb
|
sudo dpkg -i *.deb
|
||||||
|
@ -61,6 +54,9 @@ jobs:
|
||||||
sudo rm -rf /opt/ghc
|
sudo rm -rf /opt/ghc
|
||||||
sudo rm -rf "/usr/local/share/boost"
|
sudo rm -rf "/usr/local/share/boost"
|
||||||
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
|
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
|
||||||
|
- name: Clear the kernel ring buffer
|
||||||
|
run: |
|
||||||
|
sudo dmesg -c >/var/tmp/dmesg-prerun
|
||||||
- name: Tests
|
- name: Tests
|
||||||
run: |
|
run: |
|
||||||
/usr/share/zfs/zfs-tests.sh -vR -s 3G
|
/usr/share/zfs/zfs-tests.sh -vR -s 3G
|
||||||
|
@ -70,7 +66,7 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
RESULTS_PATH=$(readlink -f /var/tmp/test_results/current)
|
RESULTS_PATH=$(readlink -f /var/tmp/test_results/current)
|
||||||
sudo dmesg > $RESULTS_PATH/dmesg
|
sudo dmesg > $RESULTS_PATH/dmesg
|
||||||
sudo cp /var/log/syslog $RESULTS_PATH/
|
sudo cp /var/log/syslog /var/tmp/dmesg-prerun $RESULTS_PATH/
|
||||||
sudo chmod +r $RESULTS_PATH/*
|
sudo chmod +r $RESULTS_PATH/*
|
||||||
# Replace ':' in dir names, actions/upload-artifact doesn't support it
|
# Replace ':' in dir names, actions/upload-artifact doesn't support it
|
||||||
for f in $(find /var/tmp/test_results -name '*:*'); do mv "$f" "${f//:/__}"; done
|
for f in $(find /var/tmp/test_results -name '*:*'); do mv "$f" "${f//:/__}"; done
|
||||||
|
@ -78,5 +74,7 @@ jobs:
|
||||||
if: failure()
|
if: failure()
|
||||||
with:
|
with:
|
||||||
name: Test logs Ubuntu-${{ matrix.os }}
|
name: Test logs Ubuntu-${{ matrix.os }}
|
||||||
path: /var/tmp/test_results/20*/
|
path: |
|
||||||
|
/var/tmp/test_results/*
|
||||||
|
!/var/tmp/test_results/current
|
||||||
if-no-files-found: ignore
|
if-no-files-found: ignore
|
||||||
|
|
|
@ -6,7 +6,7 @@ on:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
tests:
|
tests:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-20.04
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
|
@ -14,24 +14,17 @@ jobs:
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install --yes -qq build-essential autoconf libtool gdb lcov \
|
xargs --arg-file=${{ github.workspace }}/.github/workflows/build-dependencies.txt sudo apt-get install -qq
|
||||||
git alien fakeroot wget curl bc fio acl \
|
sudo apt-get clean
|
||||||
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 libcurl4-openssl-dev \
|
|
||||||
python3 python3-dev python3-setuptools python3-cffi python3-packaging
|
|
||||||
- name: Autogen.sh
|
- name: Autogen.sh
|
||||||
run: |
|
run: |
|
||||||
sh autogen.sh
|
./autogen.sh
|
||||||
- name: Configure
|
- name: Configure
|
||||||
run: |
|
run: |
|
||||||
./configure --enable-debug --enable-debuginfo --enable-asan --enable-ubsan
|
./configure --enable-debug --enable-debuginfo --enable-asan --enable-ubsan
|
||||||
- name: Make
|
- name: Make
|
||||||
run: |
|
run: |
|
||||||
make --no-print-directory -s pkg-utils pkg-kmod
|
make -j$(nproc) --no-print-directory --silent pkg-utils pkg-kmod
|
||||||
- name: Install
|
- name: Install
|
||||||
run: |
|
run: |
|
||||||
sudo dpkg -i *.deb
|
sudo dpkg -i *.deb
|
||||||
|
@ -57,6 +50,9 @@ jobs:
|
||||||
sudo rm -rf /opt/ghc
|
sudo rm -rf /opt/ghc
|
||||||
sudo rm -rf "/usr/local/share/boost"
|
sudo rm -rf "/usr/local/share/boost"
|
||||||
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
|
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
|
||||||
|
- name: Clear the kernel ring buffer
|
||||||
|
run: |
|
||||||
|
sudo dmesg -c >/var/tmp/dmesg-prerun
|
||||||
- name: Tests
|
- name: Tests
|
||||||
run: |
|
run: |
|
||||||
/usr/share/zfs/zfs-tests.sh -vR -s 3G -r sanity
|
/usr/share/zfs/zfs-tests.sh -vR -s 3G -r sanity
|
||||||
|
@ -66,13 +62,15 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
RESULTS_PATH=$(readlink -f /var/tmp/test_results/current)
|
RESULTS_PATH=$(readlink -f /var/tmp/test_results/current)
|
||||||
sudo dmesg > $RESULTS_PATH/dmesg
|
sudo dmesg > $RESULTS_PATH/dmesg
|
||||||
sudo cp /var/log/syslog $RESULTS_PATH/
|
sudo cp /var/log/syslog /var/tmp/dmesg-prerun $RESULTS_PATH/
|
||||||
sudo chmod +r $RESULTS_PATH/*
|
sudo chmod +r $RESULTS_PATH/*
|
||||||
# Replace ':' in dir names, actions/upload-artifact doesn't support it
|
# Replace ':' in dir names, actions/upload-artifact doesn't support it
|
||||||
for f in $(find /var/tmp/test_results -name '*:*'); do mv "$f" "${f//:/__}"; done
|
for f in $(find /var/tmp/test_results -name '*:*'); do mv "$f" "${f//:/__}"; done
|
||||||
- uses: actions/upload-artifact@v2
|
- uses: actions/upload-artifact@v2
|
||||||
if: failure()
|
if: failure()
|
||||||
with:
|
with:
|
||||||
name: Test logs
|
name: Test logs Ubuntu-${{ matrix.os }}
|
||||||
path: /var/tmp/test_results/20*/
|
path: |
|
||||||
|
/var/tmp/test_results/*
|
||||||
|
!/var/tmp/test_results/current
|
||||||
if-no-files-found: ignore
|
if-no-files-found: ignore
|
||||||
|
|
|
@ -6,7 +6,7 @@ on:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
tests:
|
tests:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-20.04
|
||||||
env:
|
env:
|
||||||
TEST_DIR: /var/tmp/zloop
|
TEST_DIR: /var/tmp/zloop
|
||||||
steps:
|
steps:
|
||||||
|
@ -16,22 +16,17 @@ jobs:
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install --yes -qq build-essential autoconf libtool gdb \
|
xargs --arg-file=${{ github.workspace }}/.github/workflows/build-dependencies.txt sudo apt-get install -qq
|
||||||
git alien fakeroot \
|
sudo apt-get clean
|
||||||
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 \
|
|
||||||
python3 python3-dev python3-setuptools python3-cffi python3-packaging
|
|
||||||
- name: Autogen.sh
|
- name: Autogen.sh
|
||||||
run: |
|
run: |
|
||||||
sh autogen.sh
|
./autogen.sh
|
||||||
- name: Configure
|
- name: Configure
|
||||||
run: |
|
run: |
|
||||||
./configure --enable-debug --enable-debuginfo --enable-asan --enable-ubsan
|
./configure --enable-debug --enable-debuginfo --enable-asan --enable-ubsan
|
||||||
- name: Make
|
- name: Make
|
||||||
run: |
|
run: |
|
||||||
make --no-print-directory -s pkg-utils pkg-kmod
|
make -j$(nproc) --no-print-directory --silent pkg-utils pkg-kmod
|
||||||
- name: Install
|
- name: Install
|
||||||
run: |
|
run: |
|
||||||
sudo dpkg -i *.deb
|
sudo dpkg -i *.deb
|
||||||
|
|
Loading…
Reference in New Issue