obelisk 0.41.2

Deterministic workflow engine
name: release-5-verify-github-release

on:
  workflow_dispatch:
    inputs:
      ref:
        description: "The ref (branch or SHA) to obtain the tag"
        required: false
        type: string
        default: "latest"
  workflow_call:
    inputs:
      ref:
        description: "The ref (branch or SHA) to obtain the tag"
        required: false
        type: string
        default: "latest"

defaults:
  run:
    shell: bash -xe {0}

jobs:
  verify-assets:
    name: ${{ matrix.runner }}-${{ matrix.file }}
    runs-on: ${{ matrix.runner }}
    strategy:
      fail-fast: false
      matrix:
        include:
          - runner: ubuntu-22.04
            file: obelisk-x86_64-unknown-linux-gnu.tar.gz
          - runner: ubuntu-22.04
            file: obelisk-x86_64-unknown-linux-gnu-embedded.tar.gz
          - runner: ubuntu-22.04
            file: obelisk-x86_64-unknown-linux-musl.tar.gz
          - runner: ubuntu-22.04
            file: obelisk-x86_64-unknown-linux-musl-embedded.tar.gz
          - runner: macos-14
            file: obelisk-x86_64-apple-darwin.tar.gz
          - runner: macos-14
            file: obelisk-x86_64-apple-darwin-embedded.tar.gz
          - runner: macos-14
            file: obelisk-aarch64-apple-darwin.tar.gz
          - runner: macos-14
            file: obelisk-aarch64-apple-darwin-embedded.tar.gz
    steps:
      - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1
        with:
          ref: ${{ inputs.ref }}

      - id: git-info
        run: |
          VERSION="$(grep -m1 '^version = "' Cargo.toml | cut -d'"' -f2)"
          echo "version=$VERSION" >> $GITHUB_OUTPUT
          echo "tag=v$VERSION" >> $GITHUB_OUTPUT
          echo "sha=$(git rev-parse HEAD)" >> $GITHUB_OUTPUT

      - run: |
          mkdir temp
          cd temp
          # download the binary from GitHub Releases
          FILE="${{ matrix.file }}"
          curl --fail -L -o "$FILE" \
            https://github.com/obeli-sk/obelisk/releases/download/$TAG/$FILE
          tar xzfv "$FILE"
          ./obelisk --version | grep $VERSION
          ./obelisk server verify --deployment ../deployment-testing-wasm-oci.toml
        env:
          TAG: ${{ steps.git-info.outputs.tag }}
          VERSION: ${{ steps.git-info.outputs.version }}