Skip to content

rust example app

rust example app #79

Workflow file for this run

name: "Build"
on:
push:
branches: ["main"]
pull_request:
types: [opened, synchronize, reopened]
workflow_dispatch:
workflow_call:
inputs:
workflow:
required: true
type: string
secrets:
CC_BUILD_TOKEN:
required: true
GH_DOTCOM_TOKEN:
required: true
env:
REV: ${{ github.run_id }}
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-${{ inputs.workflow }}
cancel-in-progress: true
jobs:
build-release:
strategy:
matrix:
include:
- runner: "self-hosted-linux-arm"
artifact: "aranya-daemon-arm-unknown-linux-gnueabi"
- runner: "self-hosted-linux-arm64"
artifact: "aranya-daemon-aarch64-unknown-linux-gnu"
- runner: "self-hosted-linux-amd64"
artifact: "aranya-daemon-x86_64-unknown-linux-gnu"
name: build daemon ${{ matrix.artifact }}
runs-on: ${{ matrix.runner }}
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/setup
with:
ghe-token: ${{ secrets.CC_BUILD_TOKEN }}
gh-token: ${{ secrets.GH_DOTCOM_TOKEN }}
runner: ${{ matrix.runner }}
- name: Build code
run: |
cargo make build-code
cargo make tgz-daemon
- name: Verify build didn't change any checked-in files
run: cargo make git-unchanged
- name: Publish daemon
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.artifact }}
path: aranya-daemon.tar.gz
if-no-files-found: error
build-aranya-lib:
strategy:
matrix:
include:
- runner: "self-hosted-linux-arm"
artifact: "aranya-client-capi-arm-unknown-linux-gnueabi"
- runner: "self-hosted-linux-arm64"
artifact: "aranya-client-capi-aarch64-unknown-linux-gnu"
- runner: "self-hosted-linux-amd64"
artifact: "aranya-client-capi-x86_64-unknown-linux-gnu"
name: build lib ${{ matrix.artifact }}
runs-on: ${{ matrix.runner }}
steps:
- uses: actions/checkout@v3
- name: Setup Environment
uses: ./.github/actions/setup
with:
ghe-token: ${{ secrets.CC_BUILD_TOKEN }}
gh-token: ${{ secrets.GH_DOTCOM_TOKEN }}
runner: ${{ matrix.runner }}
- name: Build Aranya Shared Library
run: |
cargo make build-capi-header
cargo make build-capi-lib
cargo make tgz-capi
cargo make git-unchanged
- name: Publish aranya lib
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.artifact }}
path: aranya-client-lib.tar.gz
if-no-files-found: error