Skip to content

fix: start without BUILD.json, leaner images, Vuetify 4 typography, dev worker API key - #41

Merged
BatLeDev merged 7 commits into
masterfrom
fix-api-startup-docker-vuetify-4
Oct 18, 2026
Merged

BatLeDev merged 7 commits into
masterfrom
fix-api-startup-docker-vuetify-4

Conversation

@BatLeDev

Copy link
Copy Markdown
Member

Small fixes found while working on the dev environment pilot, independent of it.

  • fix(api): start without BUILD.json. BUILD.json is written by CI only, and it was read at module load under NODE_ENV=production, so an image built locally crashed at startup. A missing file now gives { version: 'unknown (built without CI)' }.
  • build(docker): apk upgrade, no npm/npx/corepack/yarn in the runtime images, wider .dockerignore.
    • apk upgrade picks up the Alpine security fixes released after the base image.
    • npm, npx, corepack and the yarn 1 shipped by the node base image are removed from both final images; nothing uses them at runtime.
    • .dockerignore: node_modules only matched the root folder, so COPY api api, COPY worker worker and ADD /ui ui sent the local workspace node_modules into the build, merged with the installed ones. **/node_modules fixes that. ui/dist and ui/dts are rebuilt in the image, and .git, .env, dev/logs, test-results and playwright-report are not used by any step. BUILD.json is still copied.
  • fix(ui): text-body-small instead of text-caption. text-caption has no style in Vuetify 4 (two hints in the publication actions).
  • chore(ui): eslint-plugin-vuetify flat/recommended-v4. It reports the Vuetify 4 deprecations (it flags the two text-caption above on the current master).
  • chore: erasableSyntaxOnly in the root tsconfig. Node type stripping rejects non-erasable syntax; tsc now reports it first.
  • chore: commit-msg hook lints the message file git passes ("$1"). With --edit "" commitlint read the default COMMIT_EDITMSG, so on a merge it checked the previous commit message.
  • fix(dev): seed a data-fair API key for the dev worker. The worker writes imported datasets to data-fair with dataFairAPIKey, which was empty in development unless a key made by hand was put in a gitignored file. The dev config now has a fixed key, and the test setup upserts its hash in data-fair's settings (idempotent). Checked on a dev env: called the way the worker does, the key creates a dataset as another account (201), a wrong key gets 401.

Checks: lint, type check, unit tests 30 passed (on a fresh npm ci). Not run here: the api/e2e suites and the Docker builds (left to CI).

With --edit "" commitlint read the default COMMIT_EDITMSG, so on a merge (MERGE_MSG) it checked
the previous commit message instead.
It reports the Vuetify 4 deprecations, as the text-caption class of the previous commit.
Node type stripping rejects non-erasable syntax (enums, parameter properties, namespaces): tsc
now reports it before the runtime does.
The worker writes imported datasets to data-fair with dataFairAPIKey.
In development it was empty unless a key created by hand in a local
data-fair was put in a gitignored local-development file, so imports
failed on a fresh checkout, a worktree or CI.

- worker/config/development.mjs: fixed dev key
- tests/support/data-fair.ts: upsert its sha512 hash in data-fair's
  settings (adminMode, asAccount, datasets scope), as processings does
- tests/state-setup.ts: seed it at each test run (idempotent)
@github-actions github-actions Bot added the fix label Oct 18, 2026
@BatLeDev
BatLeDev marked this pull request as ready for review October 18, 2026 20:32
@BatLeDev
BatLeDev merged commit 399e853 into master Oct 18, 2026
4 checks passed
@BatLeDev
BatLeDev deleted the fix-api-startup-docker-vuetify-4 branch October 18, 2026 20:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant