# ============================================================================= # HealthLog -- production .env example # ============================================================================= # Mirrors `scripts/env-manifest.json`. The `pnpm check-env --file # .env.production.example` CI step (see `.github/workflows/env-check.yml`) # enforces every variable declared `required: true` in the manifest has a # non-empty placeholder here, so a contributor who introduces a new # required var without updating this file fails the workflow. # # Placeholders are syntactic only -- replace with real secrets before # deploying. The check-env presence rule treats any non-empty, # non-whitespace string as "set", so the `` style below # satisfies the manifest without leaking a usable credential. # # Generate the two crypto secrets locally with: # $ openssl rand -hex 32 # ============================================================================= # ----------------------------------------------------------------------------- # Core -- required for boot # ----------------------------------------------------------------------------- DATABASE_URL="postgresql://healthlog:@db:5432/healthlog?schema=public" POSTGRES_PASSWORD="" NEXT_PUBLIC_APP_URL="https://healthlog.example.com" APP_URL="https://healthlog.example.com" ENCRYPTION_KEY="" API_TOKEN_HMAC_KEY="" # ----------------------------------------------------------------------------- # Withings OAuth -- optional integration # ----------------------------------------------------------------------------- # WITHINGS_CLIENT_ID="" # WITHINGS_CLIENT_SECRET="" # WITHINGS_WEBHOOK_SECRET="" # ----------------------------------------------------------------------------- # APNs -- iOS push (optional, all-or-none) # ----------------------------------------------------------------------------- # APNS_KEY_ID="" # APNS_TEAM_ID="" # APNS_BUNDLE_ID="" # APNS_KEY="" # OR APNS_KEY_FILE -- either one satisfies the manifest # APNS_KEY_FILE="" # ----------------------------------------------------------------------------- # Deploy webhook -- Coolify -> HealthLog auto-deploy feedback # ----------------------------------------------------------------------------- # DEPLOY_WEBHOOK_SECRET="" # ----------------------------------------------------------------------------- # Off-host backups -- all-or-none # ----------------------------------------------------------------------------- # BACKUP_S3_ENDPOINT="" # BACKUP_S3_BUCKET="" # BACKUP_S3_ACCESS_KEY="" # BACKUP_S3_SECRET_KEY="" # BACKUP_ENCRYPTION_KEY="" # ----------------------------------------------------------------------------- # Dashboard snapshot -- BUILD-TIME toggle (default ON) # ----------------------------------------------------------------------------- # The dashboard hydrates every above-the-fold tile from the single # `GET /api/dashboard/snapshot` cell so the whole strip shares one # completion moment. This is the default and the desired behaviour. # # `NEXT_PUBLIC_*` vars are inlined into the client bundle at BUILD time, # not read at runtime -- so this has NO effect on the prebuilt GHCR # image and is intentionally absent from the `docker-compose.yml` # runtime `environment:` whitelist. To fall back to the legacy # four-cell path you must rebuild the image with the var set to "false": # # $ NEXT_PUBLIC_DASHBOARD_SNAPSHOT=false pnpm build # or a Dockerfile ARG # # NEXT_PUBLIC_DASHBOARD_SNAPSHOT="false"