Preserve management container publishing after the monorepo move (#8) #12

Merged
yuris merged 1 commit from issue-8-management-publish into main 2026-07-17 20:25:40 +00:00
Owner

Closes #8.

Context

The monorepo-aware Dockerfile and workflow build context/paths were established in #6. This PR closes the remaining gap: making the publish trigger an explicit allowlist so the criterion "trigger only for management, shared deps, workspace lock/config, Docker files, or its workflow" holds precisely.

Change

.forgejo/workflows/build-publish.yml switches from paths-ignore (denylist) to paths (allowlist):

  • apps/management/** (excluding its README, docs, and docker-compose*.yml)
  • packages/** (excluding package READMEs) — shared workspace packages
  • workspace lock/config: pnpm-lock.yaml, pnpm-workspace.yaml, package.json, turbo.json
  • .dockerignore and this workflow file

Unrelated root files, docs, READMEs, store-only changes, and Compose edits no longer publish an image.

Acceptance criteria

  • Forgejo builds/publishes the management image from the monorepo (Dockerfile from #6: build context ., apps/management/docker/Dockerfile).
  • Published image runs migrations then serves (CMD node scripts/migrate.mjs && node server.js; standalone output includes scripts/, drizzle/, static assets, server files; flat prod deps overlaid for the migrate script).
  • Store-only changes do not publish a management image (not in the allowlist).
  • Changes to packages/catalog publish a management image (packages/**).
  • Existing deployment pulls the same latest image name (tags unchanged: :latest and :${sha}).
  • CONTAINER_REGISTRY_TOKEN and NEXT_PUBLIC_BETTER_AUTH_URL handling preserved.

Verification

YAML re-read and structurally valid; management standalone build confirms scripts/migrate.mjs and drizzle/ migrations land in .next/standalone/apps/management.

Closes #8. ## Context The monorepo-aware Dockerfile and workflow build context/paths were established in #6. This PR closes the remaining gap: making the publish trigger an explicit allowlist so the criterion "trigger only for management, shared deps, workspace lock/config, Docker files, or its workflow" holds precisely. ## Change `.forgejo/workflows/build-publish.yml` switches from `paths-ignore` (denylist) to `paths` (allowlist): - `apps/management/**` (excluding its README, docs, and `docker-compose*.yml`) - `packages/**` (excluding package READMEs) — shared workspace packages - workspace lock/config: `pnpm-lock.yaml`, `pnpm-workspace.yaml`, `package.json`, `turbo.json` - `.dockerignore` and this workflow file Unrelated root files, docs, READMEs, store-only changes, and Compose edits no longer publish an image. ## Acceptance criteria - [x] Forgejo builds/publishes the management image from the monorepo (Dockerfile from #6: build context `.`, `apps/management/docker/Dockerfile`). - [x] Published image runs migrations then serves (`CMD node scripts/migrate.mjs && node server.js`; standalone output includes `scripts/`, `drizzle/`, static assets, server files; flat prod deps overlaid for the migrate script). - [x] Store-only changes do not publish a management image (not in the allowlist). - [x] Changes to `packages/catalog` publish a management image (`packages/**`). - [x] Existing deployment pulls the same `latest` image name (tags unchanged: `:latest` and `:${sha}`). - [x] `CONTAINER_REGISTRY_TOKEN` and `NEXT_PUBLIC_BETTER_AUTH_URL` handling preserved. ## Verification YAML re-read and structurally valid; management standalone build confirms `scripts/migrate.mjs` and `drizzle/` migrations land in `.next/standalone/apps/management`.
Switch the build-publish trigger from a denylist to an explicit allowlist so
the management image is published only for changes that affect its runner
image: the management app, shared workspace packages, workspace lock/config,
Docker files, or this workflow. Store-only, docs, README, and Docker Compose
changes no longer rebuild the image, and packages/** changes (e.g. the shared
catalog contract) do.
yuris merged commit 996963e560 into main 2026-07-17 20:25:40 +00:00
yuris deleted branch issue-8-management-publish 2026-07-17 20:25:40 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
yuris/garage!12
No description provided.