feat: deploy through shared Caddy ingress

This commit is contained in:
2026-08-22 21:48:26 +08:00
parent e2decb9e01
commit 64404bb7cf
9 changed files with 473 additions and 3 deletions

24
.env.example Normal file
View File

@@ -0,0 +1,24 @@
# Copy to .env on the server, replace every change-me value, then chmod 600 .env.
COMPOSE_PROJECT_NAME=zarinpal_analytics
CADDY_NETWORK=caddy_proxy
# PostgreSQL. Keep the generated password URL-safe (for example: openssl rand -hex 32).
POSTGRES_DB=zarinpal
POSTGRES_USER=zarinpal
POSTGRES_PASSWORD=change-me-with-a-random-hex-value
# Redis is private but authenticated. Keep this value URL-safe too.
REDIS_PASSWORD=change-me-with-a-different-random-hex-value
# Absolute host path to the immutable first-import archive.
IMPORT_FILE=/srv/zarinpal-data/challenge_data.csv.gz
# Optional backup settings. These are reserved for the backup/restore scripts.
S3_BACKUP_BUCKET=
S3_BACKUP_PREFIX=backup/zarinpal-analytics
S3_BACKUP_ENDPOINT_URL=
S3_BACKUP_ACCESS_KEY_ID=
S3_BACKUP_SECRET_ACCESS_KEY=
BACKUP_ENCRYPTION_PASSPHRASE=
BACKUP_LOCAL_KEEP_LATEST=3
BACKUP_REMOTE_KEEP_LATEST=7