printhive/.env.example
dlawler489 a5bb4dc33d Add a nightly backup script
A dated pg_dump plus an rsync mirror of the model files, with the stack
running. The dump is read back with pg_restore -l inside the container
before it replaces the day's file, so a bad run leaves older backups
alone. Older dumps are pruned after KEEP_DAYS.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-20 16:19:21 +10:00

19 lines
824 B
Text

# Copy to .env and fill in.
DATABASE_URL=postgres://USER@localhost:5432/stl_library
PORT=3000
# Docker only: where data lives on the host. Both default to ./data beside
# docker-compose.yml. DATA_DIR takes the model files, thumbnails and previews.
DATA_DIR=/Volumes/Data/printhive
# The database is set separately, because Postgres needs a filesystem with real
# ownership and permissions — leave it on local disk if DATA_DIR is exFAT, FAT
# or a network share.
PGDATA_DIR=/Volumes/Data/printhive/pgdata
# Where tools/backup.sh writes (default ./backups) and how many days of
# database dumps it keeps (default 14). Best on a different disk from DATA_DIR.
BACKUP_DIR=/Volumes/Data/printhive-backups
KEEP_DAYS=14
# Thingiverse import — get a free app token at https://www.thingiverse.com/developers
THINGIVERSE_TOKEN=