From 5a6c84024c759048116733881fe2b0c5c890d65a Mon Sep 17 00:00:00 2001 From: teor Date: Thu, 27 Oct 2022 08:19:53 +1000 Subject: [PATCH] change(ci): Add patch jobs for lightwalletd build and getblocktemplate-rpcs tests (#5474) * Add test-all-getblocktemplate-rpcs CI patch job * Cancel concurrent in-progress zcash-lightwalletd jobs * Add a patch job for zcash-lightwalletd / Build images --- .../continous-integration-docker.patch.yml | 6 +++++ .../workflows/zcash-lightwalletd.patch.yml | 22 +++++++++++++++++++ .github/workflows/zcash-lightwalletd.yml | 9 ++++++++ 3 files changed, 37 insertions(+) create mode 100644 .github/workflows/zcash-lightwalletd.patch.yml diff --git a/.github/workflows/continous-integration-docker.patch.yml b/.github/workflows/continous-integration-docker.patch.yml index 3f4bd9b38..5cf685549 100644 --- a/.github/workflows/continous-integration-docker.patch.yml +++ b/.github/workflows/continous-integration-docker.patch.yml @@ -42,6 +42,12 @@ jobs: steps: - run: 'echo "No build required"' + test-all-getblocktemplate-rpcs: + name: Test all with getblocktemplate-rpcs feature + runs-on: ubuntu-latest + steps: + - run: 'echo "No build required"' + test-fake-activation-heights: name: Test with fake activation heights runs-on: ubuntu-latest diff --git a/.github/workflows/zcash-lightwalletd.patch.yml b/.github/workflows/zcash-lightwalletd.patch.yml new file mode 100644 index 000000000..e3d45e496 --- /dev/null +++ b/.github/workflows/zcash-lightwalletd.patch.yml @@ -0,0 +1,22 @@ +name: zcash-lightwalletd + +# When the real job doesn't run because the files aren't changed, +# run a fake CI job to satisfy the branch protection rules. +on: + pull_request: + branches: + - main + paths-ignore: + - 'zebra-rpc/**' + - 'zebrad/tests/acceptance.rs' + - 'zebrad/src/config.rs' + - 'zebrad/src/commands/start.rs' + - 'docker/zcash-lightwalletd/Dockerfile' + - '.github/workflows/zcash-lightwalletd.yml' + +jobs: + build: + name: Build images + runs-on: ubuntu-latest + steps: + - run: 'echo "No build required"' diff --git a/.github/workflows/zcash-lightwalletd.yml b/.github/workflows/zcash-lightwalletd.yml index 51c64828c..9a14c65a4 100644 --- a/.github/workflows/zcash-lightwalletd.yml +++ b/.github/workflows/zcash-lightwalletd.yml @@ -1,5 +1,14 @@ name: zcash-lightwalletd +# Ensures that only one workflow task will run at a time. Previous builds, if +# already in process, will get cancelled. Only the latest commit will be allowed +# to run, cancelling any workflows in between +# +# Cancelling old jobs is the most efficient approach, because the workflow is quick. +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} + cancel-in-progress: true + on: workflow_dispatch: