Files
mscp/.github/workflows/release.yml
Ryo Nakamura ec663cc966 bump up container image versions and drop using CPack
We have already provided DEB packages in launchpad PPA and RPM packages
in COPR. Thus, we need no more deb/rpm packages in Github releases. The
single binary build of mscp is an execptio.

Updated container image versions:
- almalinux	8.8  -> 9.3
- rocky		8.8  -> 8.9, and 9.3 is added
- alpine	3.17 -> 3.19
2024-02-04 17:22:31 +09:00

71 lines
1.8 KiB
YAML

name: release
on:
push:
tags:
- "v*.*.*"
workflow_dispatch:
env:
BUILD_TYPE: Release
jobs:
build-and-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: patch to libssh
run: patch -d libssh -p1 < patch/libssh-0.10.6-2-g6f1b1e76.patch
# TODO: just building docker does not require packages. fix CMakeLists
- name: install build dependency
run: sudo ./scripts/install-build-deps.sh
- name: Configure Cmake
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
- name: Build Containers
run: make -C ${{github.workspace}}/build docker-build-all
- name: Test
run: make -C ${{github.workspace}}/build docker-test-all
- name: Build single binary mscp
run: make -C ${{github.workspace}}/build build-single-binary
- name: Release
uses: softprops/action-gh-release@v1
with:
files: |
${{github.workspace}}/build/mscp.linux.x86_64.static
source-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: patch to libssh
run: patch -d libssh -p1 < patch/libssh-0.10.6-2-g6f1b1e76.patch
- name: Set variables
run: |
VER=$(cat VERSION)
echo "VERSION=$VER" >> $GITHUB_ENV
- name: archive
run: |
cd ..
cp -r mscp mscp-${{env.VERSION}}
tar zcvf mscp-${{env.VERSION}}.tar.gz --exclude-vcs mscp-${{env.VERSION}}
- name: Release
uses: softprops/action-gh-release@v1
with:
files: |
${{github.workspace}}/../mscp-${{env.VERSION}}.tar.gz