Fix backend image: include dist/ in the pnpm-deploy bundle
CI / test (push) Successful in 23s
CI / lint (push) Successful in 27s
CI / secrets-scan (push) Successful in 5s
CI / vuln-scan (push) Successful in 15s
CI / sast (push) Successful in 11s
CI / build-images (push) Successful in 1m48s
CI / push (push) Has been cancelled
CI / image-scan (push) Has been cancelled

The 0.1.1 image published with no dist/ at all and crashed on startup
(`Cannot find module '/app/dist/main'`). Cause: pnpm deploy uses pnpm
pack file selection, which honors .gitignore. The repo's root
.gitignore excludes dist/, so pnpm correctly omitted the compiled
JavaScript from the deploy bundle — but that's exactly what the
runtime needs.

Add an explicit `files` field to the backend's package.json listing
dist/ and prisma/. With `files` set, pnpm pack/deploy includes those
paths verbatim regardless of gitignore.

Bump 0.1.1 → 0.1.2; 0.1.1 is now occupied in Harbor by the broken
unrunnable image.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-05-06 17:26:09 -07:00
parent b7394e7a32
commit 33484dc020
+5 -1
View File
@@ -1,10 +1,14 @@
{
"name": "tehriehlbudget-backend",
"version": "0.1.1",
"version": "0.1.2",
"description": "",
"author": "",
"private": true,
"license": "UNLICENSED",
"files": [
"dist",
"prisma"
],
"scripts": {
"build": "nest build",
"format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",