Skip to content

Merge branch 'ci-cache' into chrisward/pp-readme-gh #49

Merge branch 'ci-cache' into chrisward/pp-readme-gh

Merge branch 'ci-cache' into chrisward/pp-readme-gh #49

Workflow file for this run

name: Try-runtime
on:
push:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
TRY_RUNTIME_CLI_VERSION_TAG: v0.7.0
CARGO_HOME: ./.cargo
jobs:
test-try-runtime:
strategy:
matrix:
runtime: [peregrine, spiritnet]
runs-on: ubuntu-latest
container:
image: paritytech/ci-unified:bullseye-1.74.0
if: ${{ !contains(github.event.head_commit.message, 'ci-skip-rust') }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up caching for Cargo
uses: actions/cache@v4
with:
path: ${{ secrets.CARGO_CACHE_PATH }}
key: cargo-try-runtime-${{ matrix.runtime }}-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
cargo-try-runtime-${{ matrix.runtime }}-
- name: Run try-runtime
run: |
echo "Running ${{ matrix.runtime }} runtime migration check"
echo "---------- Downloading try-runtime CLI ----------"
curl -sL https://github.com/paritytech/try-runtime-cli/releases/download/${{ env.TRY_RUNTIME_CLI_VERSION_TAG }}/try-runtime-x86_64-unknown-linux-musl -o try-runtime
chmod +x ./try-runtime
echo "Using try-runtime-cli version:"
./try-runtime --version
echo "---------- Building ${{ matrix.runtime }} runtime ----------"
cargo build --release --locked -p ${{ matrix.runtime }}-runtime --features try-runtime
echo "---------- Executing on-runtime-upgrade for ${{ matrix.runtime }} ----------"
./try-runtime --runtime ./target/release/wbuild/${{ matrix.runtime }}-runtime/${{ matrix.runtime }}_runtime.compact.compressed.wasm \
on-runtime-upgrade --disable-spec-version-check --checks=all ${{ matrix.subcommand_extra_args }} live --uri wss://${{ matrix.runtime }}.kilt.io