v2.0.1 #38
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
release: | |
types: [published] | |
workflow_dispatch: | |
jobs: | |
upload-assets: | |
strategy: | |
matrix: | |
include: | |
- target: aarch64-unknown-linux-gnu | |
os: ubuntu-20.04 | |
build_tool: cross # Use https://github.com/cross-rs/cross for ARM | |
- target: x86_64-apple-darwin | |
os: macos-latest | |
build_tool: cargo | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v3 | |
name: Install cross-compilation tools | |
- uses: taiki-e/upload-rust-binary-action@v1 | |
with: | |
bin: oracle-core | |
archive: $bin-$tag-$target | |
target: ${{ matrix.target }} | |
build_tool: ${{ matrix.build_tool }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
upload-asset-x86-ubuntu-18: | |
runs-on: ubuntu-latest | |
container: 'ubuntu:18.04' | |
steps: | |
- name: Install dependencies | |
run: | | |
apt update -y | |
apt install --no-install-recommends -y \ | |
ca-certificates curl jq zip \ | |
clang make gcc g++ libssl-dev pkg-config protobuf-compiler | |
- name: Install modern Git | |
run: | | |
apt install -y software-properties-common | |
add-apt-repository ppa:git-core/ppa | |
apt update -y | |
apt install git -y | |
- name: Install Github CLI | |
run: | | |
curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | dd of=/usr/share/keyrings/githubcli-archive-keyring.gpg \ | |
&& chmod go+r /usr/share/keyrings/githubcli-archive-keyring.gpg \ | |
&& echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | tee /etc/apt/sources.list.d/github-cli.list > /dev/null \ | |
&& apt update \ | |
&& apt install gh -y | |
- name: Install Rust toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
- uses: actions/checkout@v3 | |
- name: fit git warning of dubious ownership | |
run: git config --global --add safe.directory /__w/oracle-core/oracle-core | |
- uses: taiki-e/upload-rust-binary-action@v1 | |
with: | |
bin: oracle-core | |
archive: $bin-$tag-$target | |
target: x86_64-unknown-linux-gnu | |
build_tool: cargo | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
upload-asset-windows: | |
strategy: | |
matrix: | |
include: | |
- target: x86_64-pc-windows-msvc | |
os: windows-latest | |
build_tool: cargo | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- run: echo "VCPKG_ROOT=$env:VCPKG_INSTALLATION_ROOT" | Out-File -FilePath $env:GITHUB_ENV -Append | |
- run: vcpkg install openssl:x64-windows-static-md | |
- run: echo "OPENSSL_NO_VENDOR=1" | Out-File -FilePath $env:GITHUB_ENV -Append | |
- uses: taiki-e/upload-rust-binary-action@v1 | |
with: | |
bin: oracle-core | |
target: ${{ matrix.target }} | |
build_tool: ${{ matrix.build_tool }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |