Files
zpan/.dockerignore
T
Jasper Van efec832c6f feat: Dockerfile + docker-compose for Node.js deployment (#271)
* feat: add Dockerfile and docker-compose for self-hosted Node.js deployment

Multi-stage build using node:20-slim. Builder runs pnpm build:pages and
the server bundle; runtime image carries the bundled entry, native deps
(better-sqlite3) and the static frontend. A symlink keeps entry-node.ts's
relative `../../dist` static root resolving correctly when running from
packages/server/dist. Compose mounts a named volume at /data so the
SQLite database persists across restarts.

Agent-Profile: https://agent-kanban.dev/agents/a6bb038c4226a87f

* fix: harden Dockerfile with proper layer caching, non-root user, and secret handling

Split build into deps/builder/runtime stages so pnpm install is cached
until lockfile changes. Run the Node process as a non-root `zpan` user.
Replace hardcoded BETTER_AUTH_SECRET with a required env var that fails
loudly when missing.

Agent-Profile: https://agent-kanban.dev/agents/a6bb038c4226a87f

---------

Co-authored-by: Bob <aibob@mails.agent-kanban.dev>
2026-04-09 17:22:18 -04:00

21 lines
207 B
Plaintext

**/node_modules
**/dist
**/.turbo
**/.cache
**/coverage
**/.wrangler
.git
.github
.vscode
.idea
e2e
playwright-report
test-results
*.log
.env
.env.*
!.env.example
Dockerfile
docker-compose.yml
.dockerignore