Skip to content

feat(ci): unified build-notification action for Flex Slack alerts#340

Open
y3rsh wants to merge 3 commits into
mainfrom
feat/build-notification-action
Open

feat(ci): unified build-notification action for Flex Slack alerts#340
y3rsh wants to merge 3 commits into
mainfrom
feat/build-notification-action

Conversation

@y3rsh

@y3rsh y3rsh commented Jul 7, 2026

Copy link
Copy Markdown
Member

Overview

Formalizes Flex build Slack notifications into a single TypeScript action (build-notification), inspired by and intended to supersede:

Before: four notify-* jobs in build-ot3-actions.yml and a composite simple-build-alert action with workflow-level conditionals and duplicated inputs.

After: one notify-build job (if: always()) that passes all context; the action decides whether to send, message shape (deployed / failure / cancelled), and webhook destination (webhook_url vs webhook_url_tagged).

Follows the same pattern as build-refs: Node 24 action, unit tests, lint/format CI, and a check that committed dist/index.js is up to date.

Changelog

  • Added .github/actions/build-notification with tested routing rules and bundled dist/index.js
  • Added .github/workflows/test-build-notification.yml CI for the action
  • Replaced four notify jobs in build-ot3-actions.yml with one notify-build job
  • Removed .github/actions/simple-build-alert
  • Upgraded @actions/core to v3.x (fixes transitive undici audit findings)

Review requests

Risk assessment

Attention level: medium

Trade-offs: notification timing moves to end of workflow (single job) rather than inline after S3 upload; cache sync order unchanged from main.

Blast radius: Flex build Slack notifications only; no BitBake/build logic changes.

Mitigation: 13 unit tests for routing rules; CI verifies dist bundle; continue-on-error: true on notify step preserves build job outcome.

y3rsh added 2 commits July 7, 2026 11:40
Replace simple-build-alert and four workflow notify jobs with one
TypeScript action and a single always-on notify job. Routing rules
decide message shape and webhook destination in code.
Format action/index.ts and ignore generated dist/ in Prettier checks,
matching build-refs.
@y3rsh y3rsh requested a review from neo-jesse July 7, 2026 16:44

@neo-jesse neo-jesse left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

move-cache-sync fixes artifact upload order inside the job; it does not move Slack earlier. For “Slack right after deploy, before cache,” you’d still need an in-run-build step after upload (or merge move-cache-sync and add that step). -- is this the expected behavior now?

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.

2 participants