Skip to content

feat(#204): implement preview deployments for pull requests#335

Open
Jessepriase wants to merge 1 commit into
Core-Foundry:mainfrom
Jessepriase:feat/204-preview-deployments
Open

feat(#204): implement preview deployments for pull requests#335
Jessepriase wants to merge 1 commit into
Core-Foundry:mainfrom
Jessepriase:feat/204-preview-deployments

Conversation

@Jessepriase

Copy link
Copy Markdown

Adds two GitHub Actions workflows and a usage guide to automatically deploy an isolated frontend preview for every pull request.

  • .github/workflows/preview.yml Triggers on pull_request (opened / synchronize / reopened). Installs dependencies, builds the Vite dashboard with testnet env vars, and deploys to a Cloudflare Pages branch named pr- via cloudflare/wrangler-action. Posts a single bot comment to the PR containing the live preview URL and commit SHA; updates the same comment in place on every subsequent push (no duplicates). Uses a concurrency group so a fast-follow push cancels the in-flight deploy before starting a new one.

  • .github/workflows/preview-cleanup.yml Triggers on pull_request (closed) — covers both merge and manual close. Deletes the Cloudflare Pages branch deployment and edits the existing PR comment to show the preview has been removed.

  • PREVIEW_DEPLOYMENTS.md Documents how previews work, the required repository secrets (CLOUDFLARE_API_TOKEN, CLOUDFLARE_ACCOUNT_ID, PREVIEW_EVENTS_API_URL), one-time Cloudflare Pages project setup, environment variables used in builds, and URL isolation between PRs.
    closes [DevOps] Implement Preview Deployments for Pull Requests #204

Adds two GitHub Actions workflows and a usage guide to automatically
deploy an isolated frontend preview for every pull request.

- .github/workflows/preview.yml
  Triggers on pull_request (opened / synchronize / reopened).
  Installs dependencies, builds the Vite dashboard with testnet env
  vars, and deploys to a Cloudflare Pages branch named pr-<number>
  via cloudflare/wrangler-action. Posts a single bot comment to the PR
  containing the live preview URL and commit SHA; updates the same
  comment in place on every subsequent push (no duplicates).
  Uses a concurrency group so a fast-follow push cancels the
  in-flight deploy before starting a new one.

- .github/workflows/preview-cleanup.yml
  Triggers on pull_request (closed) — covers both merge and manual
  close. Deletes the Cloudflare Pages branch deployment and edits the
  existing PR comment to show the preview has been removed.

- PREVIEW_DEPLOYMENTS.md
  Documents how previews work, the required repository secrets
  (CLOUDFLARE_API_TOKEN, CLOUDFLARE_ACCOUNT_ID, PREVIEW_EVENTS_API_URL),
  one-time Cloudflare Pages project setup, environment variables used
  in builds, and URL isolation between PRs.
@drips-wave

drips-wave Bot commented Jun 26, 2026

Copy link
Copy Markdown

@Jessepriase 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

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.

[DevOps] Implement Preview Deployments for Pull Requests

1 participant