Skip to content

Harden deploy workflows: shared build, validated artifact promotion, and dry-run planning - #272

Merged
Busiii-adetiba merged 1 commit into
SynapsVault:mainfrom
jayejim:drips/179-180-181-182
Nov 23, 2026
Merged

Busiii-adetiba merged 1 commit into
SynapsVault:mainfrom
jayejim:drips/179-180-181-182

Conversation

@jayejim

@jayejim jayejim commented Nov 23, 2026

Copy link
Copy Markdown
Contributor

Summary

Harden deploy workflows: shared build, validated artifact promotion, and dry-run planning

What was solved

#179 — [deployment] Detect protected-branch push failures before deployment

Update the mainnet deployment workflow so it selects a supported manifest delivery path (bot PR or release artifact) and verifies that path is available before deployment begins, preventing protected-branch push failures from surfacing only after deployment completes.

Addressed:

  • Changed: .github/workflows/mainnet-deploy.yml, .github/workflows/testnet-deploy.yml, deployed/contract-ids.env, docs/CONTRACTS.md
  • Choose a supported manifest delivery path (bot PR or release artifact) for storing contract IDs instead of a direct push to a protected branch
  • Verify the chosen delivery path's availability before starting deployment so failures are detected early
  • Keep changes scoped to the deployment workflow and any minimal supporting config; do not alter contract code or unrelated workflows

#180 — [deployment] Use a tested reusable build for both deployment networks

Extract the duplicated compiler/CLI installation and WASM build steps from the mainnet and testnet deploy workflows into a shared, tested reusable workflow (or composite action), and have both network deploy workflows consume its build outputs while preserving their existing network approval behavior.

Addressed:

  • Changed: .github/workflows/mainnet-deploy.yml, .github/workflows/testnet-deploy.yml
  • Create a shared reusable build workflow (workflow_call) or composite action that installs the Rust toolchain, installs the Stellar/Soroban CLI, and builds the WASM artifacts once.
  • Update .github/workflows/mainnet-deploy.yml to consume the shared build outputs instead of repeating compiler/CLI install and WASM build steps.
  • Update .github/workflows/testnet-deploy.yml to consume the same shared build outputs.

#181 — [deployment] Promote the tested WASM bytes to mainnet

Update the mainnet deployment workflow so it promotes the exact WASM artifact validated on testnet instead of rebuilding contracts. The workflow should accept an immutable validated artifact selection (e.g., a release/artifact identifier or run ID), verify the artifact's originating commit matches the expected mainnet commit and that its checksum matches the recorded/expected checksum, then deploy those exact bytes.

Addressed:

  • Changed: .github/workflows/mainnet-deploy.yml, .github/workflows/testnet-deploy.yml, docs/CONTRACTS.md
  • Allow selection of an immutable validated artifact (e.g., via workflow_dispatch input referencing a testnet validation run/artifact or release) in .github/workflows/mainnet-deploy.yml
  • Verify the selected artifact's originating commit matches the expected commit before deployment
  • Verify the artifact checksum against the recorded/expected checksum and fail on mismatch

#182 — [deployment] Package a dry-run plan before submitting transactions

Add a dry-run deployment planning capability to the mainnet deploy workflow so maintainers can generate an inspectable plan (network, admin, source commit, artifact hashes, intended operations) without submitting any transactions. This is a workflow/scripting enhancement; no contract interface or storage changes are involved.

Addressed:

  • Changed: .github/workflows/mainnet-deploy.yml, .github/workflows/testnet-deploy.yml
  • Produce a plan containing network, admin, source commit, artifact hashes, and intended operations.
  • Support generating the plan without submitting transactions (dry-run mode).
  • Provide a focused validation check or documented example appropriate to the criteria.

Changes

  • .github/workflows/mainnet-deploy.yml (modify)
  • .github/workflows/testnet-deploy.yml (modify)
  • docs/CONTRACTS.md (modify)
  • deployed/contract-ids.env (modify)
  • README.md (modify)

Approach

  1. [deployment] Detect protected-branch push failures before deployment #179 — [deployment] Detect protected-branch push failures before deployment (Changed: .github/workflows/mainnet-deploy.yml, .github/workflows/testnet-deploy.yml, deployed/contract-ids.env, docs/CONTRACTS.md)
  2. [deployment] Use a tested reusable build for both deployment networks #180 — [deployment] Use a tested reusable build for both deployment networks (Changed: .github/workflows/mainnet-deploy.yml, .github/workflows/testnet-deploy.yml)
  3. [deployment] Promote the tested WASM bytes to mainnet #181 — [deployment] Promote the tested WASM bytes to mainnet (Changed: .github/workflows/mainnet-deploy.yml, .github/workflows/testnet-deploy.yml, docs/CONTRACTS.md)
  4. [deployment] Package a dry-run plan before submitting transactions #182 — [deployment] Package a dry-run plan before submitting transactions (Changed: .github/workflows/mainnet-deploy.yml, .github/workflows/testnet-deploy.yml)

Issues

Closes #179
Closes #179
Closes #180
Closes #180
Closes #181
Closes #181
Closes #182
Closes #182

@drips-wave

drips-wave Bot commented Nov 23, 2026

Copy link
Copy Markdown

@jayejim Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@Busiii-adetiba
Busiii-adetiba merged commit 82d2c9d into SynapsVault:main Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

2 participants