Add cargo install #3
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: Store contract artifacts | |
on: | |
push: | |
branches: | |
- add-workflow-to-store-artifacts | |
concurrency: | |
group: ${{ github.ref }}-${{ github.workflow }} | |
cancel-in-progress: true | |
jobs: | |
check: | |
runs-on: [self-hosted, Linux, X64, large] | |
steps: | |
- name: Checkout the source code | |
uses: actions/checkout@v3 | |
with: | |
submodules: true | |
- name: Install Rust toolchain | |
uses: Cardinal-Cryptography/github-actions/install-rust-toolchain@v6 | |
- name: Cache Crates | |
uses: actions/cache@v3 | |
with: | |
path: ~/.cargo | |
key: ${{ runner.os }}-rust-${{ hashFiles('rust-toolchain.toml') }} | |
restore-keys: | | |
${{ runner.os }}-rust | |
- name: Build contracts | |
run: | | |
cargo install contract | |
make build-amm | |
- name: Print out files | |
run: | | |
find artifacts | |
#- name: Store artifact in S3 bucket | |
# uses: Cardinal-Cryptography/github-actions/store-contract-artifact@v6 | |
# with: | |
# aws-access-key-id: ${{ secrets.CONTRACTS_CMN_ARTIFACTS_RW_AWS_ACCESS_KEY_ID }} | |
# aws-secret-access-key: ${{ secrets.CONTRACTS_CMN_ARTIFACTS_RW_AWS_SECRET_ACCESS_KEY }} | |
# aws-region: ${{ secrets.CONTRACTS_S3BUCKET_REGION }} | |
# s3-bucket: ${{ secrets.CONTRACTS_S3BUCKET_NAME }} | |
# project: common | |
# version: ${{ github.sha }} | |
# contract: azero_router | |
# src-artifact: artifacts/router | |
# if-exist: overwrite |