From fca4e661d95a195e1281ba4e2dedae9c5947e52e Mon Sep 17 00:00:00 2001 From: Gabriele Picco Date: Tue, 3 Nov 2026 09:56:29 +0100 Subject: [PATCH] ci: propose program upgrades from any commit, tag or branch --- .github/workflows/propose-program-upgrade.yml | 4 ++++ README.md | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/propose-program-upgrade.yml b/.github/workflows/propose-program-upgrade.yml index a3ecac02..e0d6b605 100644 --- a/.github/workflows/propose-program-upgrade.yml +++ b/.github/workflows/propose-program-upgrade.yml @@ -15,6 +15,9 @@ on: type: choice options: [devnet, mainnet] default: devnet + ref: + description: Commit SHA, release tag, or branch of the program to propose. Defaults to the ref the workflow runs on. + default: "" proposal_name: description: Squads proposal memo default: Upgrade delegation program @@ -36,6 +39,7 @@ jobs: steps: - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 with: + ref: ${{ inputs.ref }} persist-credentials: false - uses: magicblock-labs/.github/actions/squads-program-upgrade@2789218e3d6332e244eb2aa55b87cfb9c10c5a7f diff --git a/README.md b/README.md index b44316f2..e5dc8b99 100644 --- a/README.md +++ b/README.md @@ -59,7 +59,7 @@ cd tests/integration && anchor test Upgrades go through a Squads multisig whose vault holds the upgrade authority. CI only proposes them. -1. Run **Actions → Propose Program Upgrade** with the target `cluster` (start with `dry_run`). It builds `dlp` verifiably, uploads a buffer and opens a Squads proposal that upgrades the program and records its verified build. The job summary shows the proposal number and the executable hash. +1. Run **Actions → Propose Program Upgrade** with the target `cluster` (start with `dry_run`). It builds `dlp` verifiably, uploads a buffer and opens a Squads proposal that upgrades the program and records its verified build. The job summary shows the proposal number and the executable hash. Set `ref` to a commit SHA, release tag or branch to build that source instead of the one the workflow is run from. 2. Members review and approve: - **mainnet:** in the [Squads app](https://app.squads.so); - **devnet:** with the shared command-line tools, run locally with your own keypair: