Update Rust crate diesel to 2.1.2 - abandoned #3202
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: ci | |
env: | |
SGX_MODE: SW | |
IAS_MODE: DEV | |
RUST_BACKTRACE: full | |
CONSENSUS_ENCLAVE_CSS: /var/tmp/consensus-enclave.css | |
INGEST_ENCLAVE_CSS: /var/tmp/ingest-enclave.css | |
CSS_BASE_URL: https://enclave-distribution.test.mobilecoin.com | |
on: | |
pull_request: | |
branches: | |
- main | |
- release/* | |
concurrency: | |
group: full-service-ci-${{ github.head_ref || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
lint: | |
runs-on: [self-hosted, Linux, large] | |
container: | |
image: mobilecoin/rust-sgx-base:v0.0.27 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- name: Cache cargo packages | |
uses: ./.github/actions/mobilecoin-cache-cargo-package | |
with: | |
cache_buster: ${{ secrets.CACHE_BUSTER }} | |
- name: Consensus SigStruct | |
run: | | |
SIGSTRUCT_URI=$(curl -fsSL "${CSS_BASE_URL}/production.json" | jq -r .consensus.sigstruct) | |
curl -fL --retry 3 "${CSS_BASE_URL}/${SIGSTRUCT_URI}" -o "${CONSENSUS_ENCLAVE_CSS}" | |
- name: Ingest SigStruct | |
run: | | |
SIGSTRUCT_URI=$(curl -fsSL "${CSS_BASE_URL}/production.json" | jq -r .ingest.sigstruct) | |
curl -fL --retry 3 "${CSS_BASE_URL}/${SIGSTRUCT_URI}" -o "${INGEST_ENCLAVE_CSS}" | |
- name: Set Git Safe Directory | |
run: git config --global --add safe.directory /__w/full-service/full-service/ | |
- name: Cargo sort | |
run: | | |
cargo install cargo-sort --force | |
cargo sort --workspace --grouped --check | |
- name: Cargo fmt | |
run: | | |
cargo fmt -- --unstable-features --check | |
- name: Cargo Clippy | |
run: | | |
cargo clippy --all --all-features | |
test: | |
runs-on: [self-hosted, Linux, large] | |
container: | |
image: mobilecoin/rust-sgx-base:latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- name: Cache cargo packages | |
uses: ./.github/actions/mobilecoin-cache-cargo-package | |
with: | |
cache_buster: ${{ secrets.CACHE_BUSTER }} | |
- name: Consensus SigStruct | |
run: | | |
SIGSTRUCT_URI=$(curl -fsSL "${CSS_BASE_URL}/production.json" | jq -r .consensus.sigstruct) | |
curl -fL --retry 3 "${CSS_BASE_URL}/${SIGSTRUCT_URI}" -o "${CONSENSUS_ENCLAVE_CSS}" | |
- name: Ingest SigStruct | |
run: | | |
SIGSTRUCT_URI=$(curl -fsSL "${CSS_BASE_URL}/production.json" | jq -r .ingest.sigstruct) | |
curl -fL --retry 3 "${CSS_BASE_URL}/${SIGSTRUCT_URI}" -o "${INGEST_ENCLAVE_CSS}" | |
- name: Set Git Safe Directory | |
run: git config --global --add safe.directory /__w/full-service/full-service/ | |
- uses: actions-rs/cargo@v1 | |
with: | |
command: test | |
env: | |
CARGO_INCREMENTAL: "0" | |
RUSTFLAGS: "-Zprofile -Ccodegen-units=1 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off -Cpanic=abort -Zpanic_abort_tests" | |
RUSTDOCFLAGS: "-Zprofile -Ccodegen-units=1 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off -Cpanic=abort -Zpanic_abort_tests" | |
- id: coverage | |
uses: actions-rs/grcov@v0.1 | |
- name: Codecov | |
uses: codecov/codecov-action@v3.1.4 | |
with: | |
files: ${{ steps.coverage.outputs.report }} | |
verbose: true | |
fail_ci_if_error: true | |
env: | |
CODECOV_TOKEN: 5be757b6-e923-40f2-80ea-5deac1e02b1e | |
docs: | |
runs-on: [self-hosted, Linux, large] | |
container: | |
image: mobilecoin/rust-sgx-base:latest | |
permissions: | |
contents: write | |
pages: write | |
steps: | |
- name: Clone repository | |
uses: actions/checkout@v3 | |
with: | |
submodules: true | |
fetch-depth: 0 | |
- name: Restore core cache | |
uses: actions/cache/restore@v3 | |
with: | |
key: core | |
path: | | |
~/.cargo | |
./target | |
- name: Consensus SigStruct | |
run: | | |
SIGSTRUCT_URI=$(curl -fsSL "${CSS_BASE_URL}/production.json" | jq -r .consensus.sigstruct) | |
curl -fL --retry 3 "${CSS_BASE_URL}/${SIGSTRUCT_URI}" -o "${CONSENSUS_ENCLAVE_CSS}" | |
- name: Set Git Safe Directory | |
run: git config --global --add safe.directory /__w/full-service/full-service/ | |
- name: Build documentation | |
uses: actions-rs/cargo@v1 | |
with: | |
command: doc | |
args: --no-deps | |
- name: Deploy to GitHub Pages | |
uses: crazy-max/ghaction-github-pages@v3 | |
if: github.ref_name == 'main' | |
with: | |
target_branch: gh-pages | |
build_dir: target/doc | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |