-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
38 lines (33 loc) · 1.86 KB
/
Copy path.env.example
File metadata and controls
38 lines (33 loc) · 1.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# Copy to `.env` and fill in real values. `.env` is gitignored.
#
# Two valid environments share this file's structure:
#
# DEV (your laptop / dev PC, host has Postgres already):
# - Point DATABASE_URL at the existing host Postgres
# - POSTGRES_* vars are irrelevant; safe to leave as defaults
#
# PROD (shop PC, runs the full docker-compose stack):
# - DATABASE_URL must use host=postgres (the compose service name)
# - POSTGRES_PASSWORD must be a strong random value (32+ hex chars)
# - Generate secrets with:
# head -c 16 /dev/urandom | od -An -tx1 | tr -d ' \n' # password
# head -c 32 /dev/urandom | od -An -tx1 | tr -d ' \n' # cookie secret
# ─── App ─────────────────────────────────────────────────
APP_ENV=dev # dev | prod
HTTP_ADDR=:8080
RP_ATTACHMENTS_DIR=data/attachments
# ─── Database ────────────────────────────────────────────
# DEV example (host Postgres):
# DATABASE_URL=postgres://USER:PASS@localhost:5432/DBNAME?sslmode=disable
# PROD example (dockerised Postgres in the compose network):
# DATABASE_URL=postgres://rp:${POSTGRES_PASSWORD}@postgres:5432/rp?sslmode=disable
DATABASE_URL=
# Consumed only by deploy/docker-compose.yml's postgres service. In dev
# (host PG) these are ignored; in prod they must match DATABASE_URL.
POSTGRES_USER=rp
POSTGRES_DB=rp
POSTGRES_PASSWORD=
# ─── Auth ────────────────────────────────────────────────
COOKIE_SECRET=
# ─── Public access (v1.x) ────────────────────────────────
CLOUDFLARE_TUNNEL_TOKEN=