Files
teknav-bak/app/backend/.env.example
T
arsam 78c9275610 Import source: app/backend/.env.example
Import the existing local project snapshot. This commit organizes existing files; it does not represent newly developed functionality.
2026-09-18 23:18:47 +03:30

68 lines
2.7 KiB
Bash

# Backend env — copy to backend/.env and fill in for local dev.
# Production secrets live in /etc/teknav/secrets.env on the Debian host (NOT in git).
DATABASE_URL="postgresql://teknav:teknav_dev@localhost:5432/teknav?schema=public"
REDIS_URL="redis://localhost:6379"
# 32+ random bytes; required even in dev. Generate: `openssl rand -base64 48`
SESSION_SECRET="CHANGE_ME_RANDOM_BYTES_AT_LEAST_32_CHARS"
# Cookie scope. Leave empty in dev; in prod set to your apex domain (e.g. ".teknav.ir").
COOKIE_DOMAIN=""
# Where uploaded images go.
UPLOAD_DIR="./uploads"
# Comma-separated origins allowed by CORS. Use http://localhost:3009 for the Vite dev server.
CORS_ORIGINS="http://localhost:3009"
# Server port (Fastify). Frontend talks to /api/* via the reverse proxy in prod.
PORT=3010
# Pino log level: trace | debug | info | warn | error | fatal
LOG_LEVEL=info
# ── OAuth ────────────────────────────────────────────────────────────────────
# Base URL for OAuth callback redirect URIs. In dev: http://localhost:3009
OAUTH_CALLBACK_BASE=http://localhost:3009
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
GITHUB_CLIENT_ID=
GITHUB_CLIENT_SECRET=
# ── Email / SMS ──────────────────────────────────────────────────────────────
# In development, blank SMTP logs mail instead of sending it.
SMTP_HOST=
SMTP_PORT=587
SMTP_USER=
SMTP_PASS=
SMTP_FROM=no-reply@teknav.ir
# Email to receive daily client error digest (leave empty to disable)
ADMIN_ALERT_EMAIL=
SMS_PROVIDER=
SMS_API_KEY=
SMS_SENDER=
# ── Web Push ─────────────────────────────────────────────────────────────────
# Blank values make push delivery a no-op.
VAPID_PUBLIC_KEY=
VAPID_PRIVATE_KEY=
VAPID_SUBJECT=mailto:admin@teknav.ir
# ── Monetization ─────────────────────────────────────────────────────────────
# Blank merchant id makes membership subscription return payment_unavailable.
ZARINPAL_MERCHANT_ID=
ZARINPAL_SANDBOX=1
MEMBERSHIP_PRICE_IRR=5000000
MEMBERSHIP_DURATION_DAYS=365
# ── Storage ──────────────────────────────────────────────────────────────────
# Local disk is the active implementation.
STORAGE_BACKEND=local
S3_ENDPOINT=
S3_BUCKET=
S3_ACCESS_KEY=
S3_SECRET_KEY=