Skip to content

chore(release): promote v1.51.0 - #650

Merged
fredcamaral merged 18 commits into
mainfrom
develop
Aug 6, 2026
Merged

chore(release): promote v1.51.0#650
fredcamaral merged 18 commits into
mainfrom
develop

Conversation

@fredcamaral

Copy link
Copy Markdown
Member
Lerian

GitHub Actions Shared Workflows


Description

Promotes the validated develop state to main for the stable v1.51.0 release.

This promotion includes:

  • SPA Deploy reusable workflow and its S3 sync and CloudFront invalidation composites.
  • Breaking Change Guard composite with release-parser parity, shallow-history protection, literal acknowledgement matching, and a durable detector matrix.

Develop published v1.51.0-beta.2 successfully. The beta contains the Breaking Change Guard action and the release workflow completed successfully: https://github.com/LerianStudio/github-actions-shared-workflows/actions/runs/31075949056

Type of Change

  • feat: New workflow or new input/output/step in an existing workflow
  • fix: Bug fix in a workflow (incorrect behavior, broken step, wrong condition)
  • perf: Performance improvement (e.g. caching, parallelism, reduced steps)
  • refactor: Internal restructuring with no behavior change
  • docs: Documentation only (README, docs/, inline comments)
  • ci: Changes to self-CI (workflows under .github/workflows/ that run on this repo)
  • chore: Dependency bumps, config updates, maintenance
  • test: Adding or updating tests
  • BREAKING CHANGE: Callers must update their configuration after this PR

Breaking Changes

None.

Testing

  • YAML syntax validated locally
  • Triggered a real workflow run on a caller repository using @this-branch or the beta tag
  • Verified all existing inputs still work with default values
  • Confirmed no secrets or tokens are printed in logs
  • Checked that unrelated workflows are not affected

Caller repo / workflow run: Develop beta release v1.51.0-beta.2: https://github.com/LerianStudio/github-actions-shared-workflows/actions/runs/31075949056

Related Issues

Related PRs: #647 and #649.

lerian-studio and others added 15 commits August 4, 2026 18:25
Reusable workflow_call that builds a frontend SPA, authenticates to AWS via an
OIDC role (no static keys), syncs the built dist to a private S3 bucket with
differentiated Cache-Control (assets immutable, HTML no-store, HTML uploaded
last), and invalidates CloudFront. Fills the gap where s3-upload cannot deploy
an SPA (no build, no artifact input, env-folder routing, no Cache-Control, no
invalidation). SHA-pinned actions, least-priv permissions, dry_run supported.
Refactor spa-deploy.yml from an inlined build+deploy workflow into a thin
orchestrator that delegates the complex S3 sync and CloudFront invalidation
shell to single-responsibility composites, per the reusable-workflow
architecture model.

- add src/deploy/s3-sync (differentiated Cache-Control: assets immutable
  with --delete, *.html no-store uploaded last)
- add src/deploy/cloudfront-invalidate (create-invalidation, dry-run aware)
- reuse src/setup/aws-cli so composites' aws calls work on self-hosted runners
- keep OIDC-only auth and secret routing in the workflow
- add deploy label + labeler mapping for src/deploy/**
- update docs/spa-deploy.md to reflect the composite delegation
Comply with .claude/commands/workflow.md:
- Reference composites via LerianStudio/.../src/<cap>/<name>@ref instead of
  ./src/... — a local path in a workflow_call reusable resolves to the CALLER's
  workspace and breaks for external callers (critical rule).
- Remove workflow_dispatch: a reusable workflow must be workflow_call only;
  build_command is free-text and eval'd, so a manual-dispatch string input would
  be a command-injection surface.
…le HTML, doc fixes

- Dry run is now fully local: workflow skips AWS CLI + OIDC credential steps and
  the s3-sync composite prints the resolved plan (no AWS calls, no role assumed).
- s3-sync HTML pass now uses --delete scoped to *.html so obsolete HTML is pruned.
- Align deploy label description with the paths the labeler covers.
- README composite-step examples use dry-run: false (no workflow input in scope).
- docs/spa-deploy.md reflects the local dry-run behavior.
…ed short-lived creds

- environment input → job-level GitHub Environment gate (required reviewers /
  branch protection / environment-scoped OIDC trust); empty = no gate.
- concurrency group per s3_bucket with cancel-in-progress: false so a --delete
  sync never races a concurrent run.
- configure-aws-credentials: per-run role-session-name (CloudTrail attribution)
  and short role-duration-seconds (default 900, overridable).
- Stable-named non-fingerprinted files (service-worker.js, manifest.webmanifest,
  robots.txt, favicon.ico) no longer inherit the immutable 1y Cache-Control — a
  dedicated pass syncs them with a revalidation policy (configurable via
  revalidate-globs / revalidate-cache-control) so updates propagate.
- README composite-step examples are now complete workflows with the required
  runs-on: blacksmith-4vcpu-ubuntu-2404 and external composite refs.
…arify concurrency scope

- Add a dry_run-only step that emits ::notice:: with every resolved non-secret
  input (working dir, build command, dist, bucket, distribution id, region,
  environment, role duration). AWS_DEPLOY_ROLE_ARN is never echoed.
- Reword the concurrency comment + docs: GitHub concurrency is repository-scoped,
  so serialization covers a single-owner bucket, not a bucket shared across repos.
…ated bucket

- Refuse to sync when the distribution has no regular files — an empty/missing
  dist with --delete would wipe the entire bucket. Guard in the composite (safe
  standalone) and tighten the workflow's build-output check to regular files.
- Document that the bucket must be dedicated (--delete prunes the root).
… step

Co-authored-by: Codesmith <codesmith-bot@users.noreply.github.com>
@fredcamaral
fredcamaral requested a review from a team as a code owner August 6, 2026 06:07
@coderabbitai

coderabbitai Bot commented Aug 6, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 732fc687-4045-4f63-b393-24be23cf8274

📥 Commits

Reviewing files that changed from the base of the PR and between 3af8d2c and 907a377.

📒 Files selected for processing (1)
  • .github/workflows/spa-deploy.yml

Summary by CodeRabbit

  • New Features
    • Added reusable SPA deployment automation for building, validating, and deploying assets to S3 and CloudFront.
    • Added S3 synchronization and CloudFront invalidation actions with safe dry-run support and cache handling.
    • Added breaking-change detection and approval validation for pull requests.
  • Documentation
    • Added usage guides and examples for deployment and validation workflows.
  • Tests
    • Added comprehensive validation coverage for breaking-change detection.
  • Chores
    • Added automatic deployment labeling and breaking-change validation to repository workflows.

Walkthrough

Changes

The pull request adds reusable SPA deployment workflows and composite actions for S3 and CloudFront. It also adds a breaking-change guard action, integration tests, documentation, CI execution, and deployment labeling.

SPA deployment automation

Layer / File(s) Summary
Deployment composite actions
src/deploy/cloudfront-invalidate/action.yml, src/deploy/s3-sync/action.yml
Adds CloudFront invalidation and ordered S3 synchronization actions with dry-run support, cache policies, deletion scopes, and distribution validation.
Reusable SPA deployment workflow
.github/workflows/spa-deploy.yml
Adds workflow-call inputs, OIDC authentication, concurrency control, SPA build validation, dry-run handling, and deployment action wiring.
Deployment documentation and labeling
docs/spa-deploy.md, src/deploy/*/README.md, .github/labeler.yml, .github/labels.yml
Documents the deployment contracts and assigns the deploy label to deployment sources and workflows.

Breaking-change validation

Layer / File(s) Summary
Breaking-change detector action
src/validate/breaking-change-guard/action.yml, src/validate/breaking-change-guard/detect.sh
Adds a composite action that parses commit messages, checks acknowledgement text, and exposes detection and approval outputs.
Detector test and CI validation
src/validate/breaking-change-guard/test.sh, .github/workflows/self-pr-validation.yml, src/validate/breaking-change-guard/README.md
Adds integration coverage for parsing and failure cases, runs it in self-validation, and documents the action contract.

Estimated code review effort: 4 (Complex) | ~60 minutes

Possibly related PRs

Suggested reviewers: ferr3ira-gabriel, gauchito91, guimoreirar, jeffersonrodrigues92, prymax10

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies this pull request as the stable v1.51.0 release promotion.
Description check ✅ Passed The description covers the release scope, change type, breaking changes, validation, workflow run, and related pull requests.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch develop

Comment @coderabbitai help to get the list of available commands.

@lerian-studio lerian-studio added size/XL PR changes ≥ 1000 lines — consider splitting documentation Improvements or additions to documentation workflow Changes to one or more reusable workflow files github-config Changes to repository configuration (templates, CODEOWNERS, labeler, etc.) validate Changes to PR validation composite actions (src/validate/) composite Changes to any composite action manifest (src/**/*.yml) scripts Changes to shell scripts (src/**/*.sh) deploy Changes to deployment composites and workflows (src/deploy/, spa-deploy.yml, s3-upload.yml) labels Aug 6, 2026
@lerian-studio

lerian-studio commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

🔍 PR Validation Summary

✅ PR Mergeable — no blocking failures

Check Status Blocking
Source Branch ✅ success yes
PR Title ✅ success yes
PR Description ✅ success yes
PR Size ✅ success no
Auto Labels ✅ success no
PR Metadata ✅ success no

🔍 View workflow run

@lerian-studio

lerian-studio commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

🛡️ CodeQL Analysis Results

Languages analyzed: actions

✅ No security issues found.


🔍 View full scan logs | 🛡️ Security tab

@lerian-studio

lerian-studio commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

🔍 Lint Analysis

Check Files Scanned Status
YAML Lint 7 file(s) ✅ success
Action Lint 2 file(s) ✅ success
Pinned Actions 5 file(s) ✅ success
Markdown Link Check 4 file(s) ✅ success
Spelling Check 13 file(s) ✅ success
Shell Check 5 file(s) ✅ success
README Check 5 file(s) ✅ success
Composite Schema 3 file(s) ✅ success
Deployment Matrix no changes ⏭️ skipped

🔍 View full scan logs

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Warning

CodeRabbit couldn't request changes on this pull request because it doesn't have sufficient GitHub permissions.

Please grant CodeRabbit Pull requests: Read and write permission and re-run the review.

👉 Steps to fix this

Actionable comments posted: 3

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/spa-deploy.yml:
- Around line 163-184: Update the “Dry-run deployment plan (resolved inputs)”
step to expose the missing resolved inputs: add NODE_VERSION from
inputs.node_version and print it, and add DRY_RUN from inputs.dry_run and print
it alongside the other plan values. Preserve the existing
environment-variable-based output structure.
- Around line 209-216: Update the deployment composite references in the
spa-deploy workflow, specifically the S3 sync and CloudFront invalidation steps,
to use an immutable released tag containing both composites instead of the
mutable `@develop` reference. Prefer `@v1` once available; otherwise use the
appropriate released tag.

In `@src/validate/breaking-change-guard/README.md`:
- Around line 75-78: Update the README examples using actions/checkout to
include a concise note explaining that it materializes HEAD and fetches full
history needed to resolve origin/<base-ref>..HEAD. Apply the note consistently
to the checkout usages in all referenced examples.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yml

Review profile: ASSERTIVE

Plan: Pro

Run ID: e2db8e7b-b794-4fa0-899d-7480bdd0bd23

📥 Commits

Reviewing files that changed from the base of the PR and between b188931 and cc36bf6.

📒 Files selected for processing (13)
  • .github/labeler.yml
  • .github/labels.yml
  • .github/workflows/self-pr-validation.yml
  • .github/workflows/spa-deploy.yml
  • docs/spa-deploy.md
  • src/deploy/cloudfront-invalidate/README.md
  • src/deploy/cloudfront-invalidate/action.yml
  • src/deploy/s3-sync/README.md
  • src/deploy/s3-sync/action.yml
  • src/validate/breaking-change-guard/README.md
  • src/validate/breaking-change-guard/action.yml
  • src/validate/breaking-change-guard/detect.sh
  • src/validate/breaking-change-guard/test.sh

Comment thread .github/workflows/spa-deploy.yml
Comment thread .github/workflows/spa-deploy.yml Outdated
Comment thread src/validate/breaking-change-guard/README.md
Co-authored-by: Codesmith <codesmith-bot@users.noreply.github.com>
…(breaking-change-guard): explain checkout requirement

Co-authored-by: Codesmith <codesmith-bot@users.noreply.github.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Warning

CodeRabbit couldn't request changes on this pull request because it doesn't have sufficient GitHub permissions.

Please grant CodeRabbit Pull requests: Read and write permission and re-run the review.

👉 Steps to fix this

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/spa-deploy.yml:
- Around line 213-220: Publish the stable shared workflow version v1.51.0,
including both the S3 sync and CloudFront invalidation composites, before
promoting SPA Deploy. Then update the deploy steps to reference the stable
`@v1.51.0` release and remove both TODO comments from the workflow.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 9dc66dcd-cecc-4675-be6a-f9c7a1baedc0

📥 Commits

Reviewing files that changed from the base of the PR and between 13b2f05 and 3af8d2c.

📒 Files selected for processing (2)
  • .github/workflows/spa-deploy.yml
  • src/validate/breaking-change-guard/README.md

Comment thread .github/workflows/spa-deploy.yml Outdated
@fredcamaral

Copy link
Copy Markdown
Member Author

@BlackSmith -- ainda temos um minor do coderabbit que faz sentido.

@blacksmith-sh

blacksmith-sh Bot commented Aug 6, 2026

Copy link
Copy Markdown

Got it, I'm reviewing the PR details now.

Co-authored-by: Codesmith <codesmith-bot@users.noreply.github.com>
@blacksmith-sh

blacksmith-sh Bot commented Aug 6, 2026

Copy link
Copy Markdown

@fredcamaral

@BlackSmith -- ainda temos um minor do coderabbit que faz sentido.

O minor que sobrou faz sentido sim, e a razão é a própria política do repo: src/lint/pinned-actions aceita para composites internos apenas @vN (major flutuante) ou develop/main, então o pin em v1.51.0-beta.2 gerava os dois warnings do Pinned Actions Check e contrariava a convenção usada logo acima no mesmo job (src/setup/aws-cli@v1).

O argumento "chicken-and-egg" da minha resposta anterior não se aplica a @v1: o v1 é force-pushed a cada release (src/config/update-major-tag), então assim que este PR de promoção mergear e o semantic-release publicar v1.51.0, @v1 passa a conter os dois composites. É exatamente o mesmo bootstrap já documentado em .github/workflows/end-to-end-tests.yml:87. E spa-deploy.yml não é exercitado pelo CI deste repo a partir de develop, então não há janela de quebra antes do merge.

Commit 907a377 em develop:

      # Composites are pinned to the floating major tag (@v1) per the internal
      # pinning policy (src/lint/pinned-actions). The v1 tag advances on every
      # release, so both composites resolve as soon as this promotion ships and
      # semantic-release moves v1 forward (same bootstrap as end-to-end-tests.yml).
      - name: Sync SPA to S3 (differentiated Cache-Control)
        uses: LerianStudio/github-actions-shared-workflows/src/deploy/s3-sync@v1

Ambos os TODOs foram removidos, e os warnings do Pinned Actions Check devem zerar no próximo run.

View with [code]smith

@fredcamaral
fredcamaral merged commit e90d7f6 into main Aug 6, 2026
33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

composite Changes to any composite action manifest (src/**/*.yml) deploy Changes to deployment composites and workflows (src/deploy/, spa-deploy.yml, s3-upload.yml) documentation Improvements or additions to documentation github-config Changes to repository configuration (templates, CODEOWNERS, labeler, etc.) scripts Changes to shell scripts (src/**/*.sh) size/XL PR changes ≥ 1000 lines — consider splitting validate Changes to PR validation composite actions (src/validate/) workflow Changes to one or more reusable workflow files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants