Skip to content

ci: add release + CI pipelines; ship platform binaries (v0.3.3) #6

ci: add release + CI pipelines; ship platform binaries (v0.3.3)

ci: add release + CI pipelines; ship platform binaries (v0.3.3) #6

Workflow file for this run

name: release
on:
push:
tags:
- "v*"
permissions:
contents: write
id-token: write
env:
# GitHub Actions runner Node 20 -> Node 24 deprecation (effective 2026-06-02).
# Forces JS-based actions onto Node 24 ahead of the cutover.
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
jobs:
build:
name: build ${{ matrix.target }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
target: x86_64-unknown-linux-gnu
archive: tar.gz
- os: ubuntu-latest
target: aarch64-unknown-linux-gnu
archive: tar.gz
cross: true
- os: macos-latest
target: x86_64-apple-darwin
archive: tar.gz
- os: macos-latest
target: aarch64-apple-darwin
archive: tar.gz
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}
- uses: Swatinem/rust-cache@v2
- name: install cross
if: matrix.cross
run: cargo install cross --git https://github.com/cross-rs/cross --locked
- name: build (cross)
if: matrix.cross
run: cross build --release --target ${{ matrix.target }}
- name: build (native)
if: '!matrix.cross'
run: cargo build --release --target ${{ matrix.target }}
- name: package
run: |
mkdir -p dist
BIN=animus-queue-default
ARCHIVE="${BIN}-${{ matrix.target }}.tar.gz"
tar -C target/${{ matrix.target }}/release -czf "dist/${ARCHIVE}" "${BIN}"
( cd dist && shasum -a 256 "${ARCHIVE}" > "${ARCHIVE}.sha256" )
- name: Install cosign
uses: sigstore/cosign-installer@v3.7.0
- name: Sign archive with cosign (keyless)
run: |
set -euo pipefail
BIN=animus-queue-default
ARCHIVE="${BIN}-${{ matrix.target }}.tar.gz"
cd dist
cosign sign-blob \
--yes \
--bundle "${ARCHIVE}.bundle" \
"${ARCHIVE}"
- uses: softprops/action-gh-release@v2
with:
files: dist/*