Skip to content

ci(deploy): post PR status comments and store deployment info#442

Merged
vitormattos merged 1 commit into
mainfrom
feat/pr-deploy-status-comments
Jul 9, 2026
Merged

ci(deploy): post PR status comments and store deployment info#442
vitormattos merged 1 commit into
mainfrom
feat/pr-deploy-status-comments

Conversation

@vitormattos

Copy link
Copy Markdown
Member

What

  • Posts a 🚀 Starting production deploy... comment on the PR that triggered the deploy (push events only)
  • Writes build_production/_deployment-info.json with commit_sha, pr_number, pr_title, repository and timestamp after the build

Why

Provides deploy status visibility directly in the PR timeline. The _deployment-info.json file is served at https://libresign.coop/_deployment-info.json after the GitHub Pages deployment and is consumed by the WordPress webhook handler (see companion PR in wordpress-theme) to post a ✅ fragments synced comment after the sync completes.

How it works

push to main (merge PR)
  → Deploy workflow starts
    → comment: 🚀 Starting production deploy...
    → build (composer prod)
    → write _deployment-info.json
    → push to gh-pages
  → pages-build-deployment completes (libresign.coop updated)
  → GitHub webhook fires to WordPress
    → fragments synced
    → comment: ✅ Header and footer updated!

At the start of every push-triggered Deploy run:
- Find the merged PR associated with the head commit via GitHub API
- Post '🚀 Starting production deploy...' on that PR

After a successful build:
- Write build_production/_deployment-info.json with commit_sha, pr_number,
  pr_title, repository and timestamp so the WordPress sync handler can
  post a 'finished' comment after the fragments are updated.

Signed-off-by: Vitor Mattos <1079143+vitormattos@users.noreply.github.com>
@vitormattos
vitormattos merged commit 5891f1b into main Jul 9, 2026
5 checks passed
@vitormattos
vitormattos deleted the feat/pr-deploy-status-comments branch July 9, 2026 18:14
@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

🚀 Starting production deploy of site header and footer fragments...

@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor
PR Preview Action v1.8.1

QR code for preview link

🚀 View preview at
https://libresign.github.io/site-preview/pr-preview/pr-442/

Built to branch main at 2026-07-09 18:11 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

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