-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
29 lines (23 loc) · 1.2 KB
/
.env.example
File metadata and controls
29 lines (23 loc) · 1.2 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
# fxfiles-analytics configuration
# Copied into /etc/fxfiles-analytics/fxfiles-analytics.env by install.sh.
# Server
LISTEN_ADDR=127.0.0.1:8080
# PostgreSQL — set by the installer. Format:
# postgres://USER:PASSWORD@HOST:PORT/DBNAME?sslmode=disable
# For a shared container reuse, point at postgres-pinning's mapped port
# (typically 127.0.0.1:5432). For a dedicated postgres-analytics container,
# the installer maps it to 127.0.0.1:5433.
PG_DSN=postgres://analytics_user:CHANGEME@127.0.0.1:5433/fxfiles_analytics?sslmode=disable
# Origin / Referer suffix allowlist for /api/v1/track. Comma-separated.
# Requests presenting a non-matching Origin or Referer are rejected 403.
ALLOWED_GATEWAYS=.ipfs.dweb.link,.ipfs.cloud.fx.land
# Per-IP-per-CID rate limit on /api/v1/track.
RATE_LIMIT_PER_MIN=60
# Hard cap on distinct CIDs stored. Beyond this, new CID pageviews are
# rejected with 503 to bound storage growth from spoofing.
MAX_DISTINCT_CIDS=100000
# CIDRs of upstream proxies whose X-Forwarded-For / X-Real-IP we trust.
# For an nginx-on-localhost deploy (what install.sh sets up), the default
# is correct. If you front the service with a CDN, add the CDN's egress
# ranges here.
TRUSTED_PROXIES=127.0.0.1/32,::1/128