Skip to content

ci: use dappnode-build-hash reusable workflow#117

Merged
3alpha merged 1 commit into
mainfrom
refactor/use-dappnode-build-hash
Jul 10, 2026
Merged

ci: use dappnode-build-hash reusable workflow#117
3alpha merged 1 commit into
mainfrom
refactor/use-dappnode-build-hash

Conversation

@3alpha

@3alpha 3alpha commented Jul 10, 2026

Copy link
Copy Markdown
Member

Context

This repo'''s build pipeline (an inlined build-test step with --skip_save) never pinned to IPFS or posted a comment on PRs, so tropibot bumps had no installable artifact for testers.

Approach

  • .github/workflows/build.yml (new) — thin stub calling dappnode-build-hash@master with secrets: inherit. Triggers on push (non-default branch) and workflow_dispatch only.
  • .github/workflows/main.yml — slimmed to the release job only. build-test removed; actions/checkout upgraded to v7; Node 24 with actions/setup-node@v6. Dropped the redundant if: condition. Added repository_dispatch to triggers.

Test instructions

  1. Push a commit to a non-default branch (or open a test PR).
  2. Verify the Build workflow runs once and posts a comment with an IPFS install link and hash tagged (by dappnodebot/build-action) and authored by tropibot[bot].
  3. After merge to main, the Main workflow should run the release.

Replaces the inlined build-test (which used `--skip_save` and never
posted an IPFS hash on PRs) with a thin caller for the new
`dappnode/workflows/.github/workflows/dappnode-build-hash.yml@master`
reusable workflow. `build.yml` (new) handles push (non-default branch)
and workflow_dispatch; `main.yml` is reduced to the release job only.

Also:
- Upgrades `actions/checkout` to v7 and adds Node 24 setup
  (`actions/setup-node@v6`) for the release job.
- Drops the redundant `if:` condition on the release job.
- Adds `repository_dispatch` to the `on:` triggers.
- Removes the now-unused `PINATA_API_KEY` / `PINATA_SECRET_API_KEY`
  from the release job (only `build.yml` needs them).
- Removes the stale `master` branch from `on.push.branches` (NEAR's
  default branch is `main`).
- Removes the `pull_request` trigger from `main.yml` (now in build.yml).
- Adds `branches-ignore: ["main"]` to `build.yml`'s push trigger so
  the workflow doesn't run on default-branch pushes (the SDK already
  auto-detects and does a no-op test build in that case).

The reusable workflow auto-detects the event: on push to a non-default
branch it builds, pins to Pinata, and posts a comment authored by
tropibot[bot] on the PR; on push to the default branch it does a
test build only.
@3alpha 3alpha self-assigned this Jul 10, 2026
@tropibot

tropibot Bot commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Dappnode bot has built and pinned the built packages to an IPFS node, for commit: a05b33a

This is a development version and should only be installed for testing purposes.

  1. Package near.dnp.dappnode.eth

Install link

Hash: /ipfs/QmaqESGrHcw39J8ExGZPdfzLRxCjbcGgDNTiddAP8TAMt7

(by dappnodebot/build-action)

@3alpha 3alpha merged commit 91d71a2 into main Jul 10, 2026
1 check passed
@3alpha 3alpha deleted the refactor/use-dappnode-build-hash branch July 10, 2026 09:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant