fce71bb946
Bundle the app + Postgres into a compose stack on top of the existing image.
- app: builds the image, publishes ${APP_PORT:-42776}, reads .env, pins
STATIC_DIR so SPA serving can't be disabled by an empty value
- db: postgres:14-alpine under the "with-db" profile; toggle it off via
COMPOSE_PROFILES to point the app at a Postgres on the host instead
(host.docker.internal), with depends_on required:false so it stays optional
Storage and the DB data dir each default to a named volume but can be bind
mounted to a host folder via FILES_DIR / THUMBS_DIR / IMPORT_DIR / DB_DIR.
Add PUID/PGID (via user:) so bind-mounted folders are writable by the
non-root container.
Run the container as a dedicated non-root user "tanabata" with uid/gid 42776,
reusing the project's signature number (also the default port). Document every
variable in .env.example.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
34 lines
573 B
Plaintext
34 lines
573 B
Plaintext
# Keep the build context small and reproducible: never ship local state,
|
|
# dependencies, or build outputs — they are rebuilt inside the image.
|
|
|
|
# VCS / tooling
|
|
.git
|
|
.gitignore
|
|
**/.DS_Store
|
|
|
|
# Compose file — used to build/run, not needed inside the image context
|
|
docker-compose.yml
|
|
docker-compose.*.yml
|
|
|
|
# Secrets and local env
|
|
.env
|
|
.env.*
|
|
!.env.example
|
|
|
|
# Node
|
|
frontend/node_modules
|
|
frontend/.svelte-kit
|
|
frontend/build
|
|
frontend/.vite
|
|
|
|
# Go
|
|
backend/server
|
|
backend/**/*.test
|
|
|
|
# Docs / reference (not needed to build the image)
|
|
docs/reference
|
|
|
|
# Editor / OS
|
|
.vscode
|
|
.idea
|