Repository navigation
CI: gate deploys on tests; upgrade to Node 24 LTS and nginx 1.30 - #7
Merged
Merged
Conversation
- Add a test job (lint, vitest, server tests, build + bundle budget) that runs on PRs and must pass before build-and-deploy on main. - Dockerfile: node:20-alpine (EOL) -> node:24-alpine; nginx:1.27-alpine -> nginx:1.30-alpine (Alpine 3.24, packaged Node 24 for the sidecars). - better-sqlite3 11 -> 12 for Node 24 prebuilt binaries. - sharp 0.35.5 (librsvg CVE fix, used by the OG renderer). - Pin Node via .nvmrc; snapshot workflow uses it too. - Declare allowScripts for native deps (npm install-scripts gate). - npm audit fix for dev-only advisories (vitest, xmldom, humanfs). Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
maindeployed straight to production with no lint/test step.node:20-alpine(Node 20 reached EOL April 2026); runtime usednginx:1.27-alpine.Changes
deploy.yml): newtestjob —npm ci, lint, vitest, server tests (npm run test:server), andnpm run build(typecheck + bundle budget). Runs on PRs;build-and-deploynowneeds: testand is skipped for PRs.node:24-alpinebuild stage;nginx:1.30-alpineruntime (Alpine 3.24 ships Node 24 for the OG/dev-todos/broadband sidecars).prepare/pragma/get/all) unchanged..nvmrc= 24, used by both workflows.allowScriptsinpackage.jsonfor native deps (npm's new install-scripts approval gate).npm audit fixfor dev-only advisories (vitest, xmldom, humanfs).Verification (local, Node 24.21)
npm ci✅, lint ✅, 205/205 unit tests ✅, 3/3 server tests ✅, build + bundle budget ✅, better-sqlite3 + sharp load/render ✅.main.Known remaining
mapshaper(dev-only build tool); the only fix is a major downgrade, so left as-is.