Skip to content

Use SPDK v24.01

Use SPDK v24.01 #125

Workflow file for this run

name: Ubicloud SPDK release
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
jobs:
build:
name: Build ${{ matrix.platform }}
runs-on: ${{ matrix.runner }}
strategy:
fail-fast: false
matrix:
include:
- runner: ubicloud-standard-4
platform: x64
target_arch: corei7
- runner: ubicloud-standard-4-arm
platform: arm64
target_arch: native
env:
INSTALL_PREFIX: ${{ github.workspace }}/install/spdk
TARBALL_PATH: ${{ github.workspace }}/ubicloud-spdk-ubuntu-22.04-${{ matrix.platform }}.tar.gz
permissions:
contents: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
submodules: 'recursive'
- name: Check formatting
run: .github/scripts/check-format.sh
- name: Checkout SPDK and submodules
uses: actions/checkout@v4
with:
repository: spdk/spdk
ref: refs/tags/v24.01
fetch-depth: 0
submodules: 'recursive'
path: 'spdk'
- name: Install dependencies
run: |
sudo apt-get update
sudo apt install liburing-dev lcov
sudo spdk/scripts/pkgdep.sh
- name: Configure
run: spdk/configure --with-crypto --with-vhost --without-nvme-cuse --target-arch=${{ matrix.target_arch }} --prefix=$INSTALL_PREFIX --disable-unit-tests --disable-tests --disable-examples
- name: Build SPDK
run: cd spdk && make -j16
- name: Install
run: |
cd spdk
make install
mdkdir -p $INSTALL_PREFIX/python
cp -R python/* $INSTALL_PREFIX/python/
mkdir $INSTALL_PREFIX/scripts
cp scripts/rpc.py $INSTALL_PREFIX/scripts
- name: Run tests and check coverage
run: |
sudo spdk/scripts/setup.sh
export SPDK_PATH=$INSTALL_PREFIX
make clean
make COVERAGE=true
make check
.github/scripts/check-coverage.sh
- name: Build bdev_ubi
run: |
export SPDK_PATH=$INSTALL_PREFIX
make clean
make
cp bin/vhost_ubi $INSTALL_PREFIX/bin/
- name: Package
run: |
cd $INSTALL_PREFIX/..
tar --create --gzip --file=$TARBALL_PATH spdk
- uses: ncipollo/release-action@v1
if: github.event_name == 'workflow_dispatch' && github.ref_type == 'tag'
with:
artifacts: "${{ env.TARBALL_PATH }}"
body: "Release ${{ github.ref_name }}"
allowUpdates: true