-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
210 lines (167 loc) · 9.35 KB
/
Copy path.env.example
File metadata and controls
210 lines (167 loc) · 9.35 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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
# gmmff signaling server — environment configuration
#
# Installed at: /etc/gmmff/gmmff.env
# Loaded by: /etc/systemd/system/gmmff.service (EnvironmentFile=)
# docker-compose.yml (env_file: configs/.env)
#
# To apply changes without editing the service file:
# 1. Edit this file
# 2. sudo systemctl reload-or-restart gmmff
#
# Never commit a filled-in copy of this file to version control.
# ── Container user (Docker only) ──────────────────────────────────────────────
# UID and GID the container process runs as.
# Set these to match your host user so mounted volumes have the right ownership.
# Run `id` on your host to find your UID/GID.
# Defaults to 10001:10001 if not set.
PUID=10001
PGID=10001
# ── Network ───────────────────────────────────────────────────────────────────
# TCP address the server listens on.
# Behind a reverse proxy (Caddy, nginx, AWS ALB) keep this as a local port.
GMMFF_ADDR=:8080
# ── Web UI (optional) ───────────────────────────────────────────────────────
# Use Content-Security-Policy-Report-Only instead of enforcing CSP.
# Violations are logged to the browser console but NOT blocked.
# Useful for debugging CSP issues. NOT for production.
# There is no environment variable for this flag — pass it on the command
# line only, as a reminder that it must never be set permanently:
# gmmff serve --csp-report-only
# Path to the web/static directory containing the browser UI.
# When set, gmmff serves the Wasm browser UI at / in addition to the
# signaling server at /ws. Leave empty to show the plain landing page.
#
# In Docker the static files are baked into the image at /web/static:
GMMFF_WEB_DIR=/web/static
#
# For a bare-metal install, build Wasm first (make wasm) then set:
# GMMFF_WEB_DIR=/opt/gmmff/web/static
# ── Redis / Valkey ────────────────────────────────────────────────────────────
# Connection URL for the slot store. Redis and Valkey are both supported —
# Valkey is a wire-compatible drop-in, so the same client talks to either.
# Formats:
# redis://[user:password@]host[:port][/db] (TCP — Redis or Valkey)
# rediss://[user:password@]host[:port][/db] (TLS)
# valkey://[user:password@]host[:port][/db] (alias for redis://)
# valkeys://[user:password@]host[:port][/db] (alias for rediss://)
# unix:///var/run/redis/redis.sock (Unix socket — same host)
# redis+sentinel://master@sentinel1:port,sentinel2 (Sentinel)
#
# To run Valkey instead of Redis via docker-compose, set in your shell/.env:
# GMMFF_CACHE_IMAGE=valkey/valkey:8-alpine
# GMMFF_CACHE_SERVER=valkey-server
#
# Unix socket is recommended when Redis runs on the same machine as gmmff.
# It skips the TCP stack entirely and is measurably faster.
#
# To use a Unix socket:
# 1. Add to /etc/redis/redis.conf:
# unixsocket /var/run/redis/redis.sock
# unixsocketperm 770
# 2. Add gmmff to the redis group:
# sudo usermod -aG redis gmmff
# 3. Set this variable:
GMMFF_REDIS_URL=redis://redis:6379/0
# GMMFF_REDIS_URL=unix:///var/run/redis/redis.sock
# ── Logging ───────────────────────────────────────────────────────────────────
# Log level: trace | debug | info | warn | error
# Use "info" in production. "debug" in staging.
GMMFF_LOG_LEVEL=info
# ── TLS (optional) ────────────────────────────────────────────────────────────
# Recommended: terminate TLS at a reverse proxy. Use these only if gmmff
# terminates TLS directly (no proxy in front).
# GMMFF_TLS_CERT=/etc/gmmff/tls.crt
# GMMFF_TLS_KEY=/etc/gmmff/tls.key
# ── UI feature flags ──────────────────────────────────────────────────────────
# These are served to the browser via GET /config.json and control what the
# Wasm webclient shows. All default to the most permissive setting.
# Show/hide the Files tab.
# GMMFF_SHOW_FILES=true
# Show/hide the Chat tab.
# GMMFF_SHOW_CHAT=true
# Show the ICE settings panel (STUN/TURN configuration in the browser UI).
# GMMFF_SHOW_ICE_SETTINGS=true
# Allow users to modify STUN servers (requires GMMFF_SHOW_ICE_SETTINGS=true).
# GMMFF_ALLOW_STUN=true
# Allow users to modify TURN servers (requires GMMFF_SHOW_ICE_SETTINGS=true).
# GMMFF_ALLOW_TURN=true
# Show the "Copy link" share button on code screens.
# GMMFF_SHOW_SHARE_LINK=true
# Show QR codes on code screens.
# GMMFF_SHOW_QR_CODE=true
# Allow users to change the signaling server URL in the UI.
# When false (default), the UI always connects to the server that served the page.
# GMMFF_ALLOW_CUSTOM_SERVER=false
# Show the max-peers slider. When false, the slider is hidden and
# GMMFF_MAX_PEERS_LIMIT is silently enforced.
# GMMFF_SHOW_PEERS_LIMIT=true
# Hard cap on the max-peers slider (2–10). Users cannot exceed this value.
# GMMFF_MAX_PEERS_LIMIT=10
# Sliding window size for transfer flow control (1–16, server-enforced only).
# GMMFF_MAX_WINDOW=2
# Maximum chunk size in bytes (1024–65526, server-enforced only).
# GMMFF_MAX_CHUNK_SIZE=65526
# Comma-separated list of allowed language codes, or "all" for no restriction.
# When set to a single language code, the language picker is hidden.
# Example: GMMFF_ALLOWED_LANGS=en,es,fr
# GMMFF_ALLOWED_LANGS=all
# Message of the day shown as a banner at the top of the UI.
# Leave empty or unset to show no message.
# Tab display order — comma-separated list of: files, chat, schedule
# Default: files,chat,schedule
# Example to put Schedule first: GMMFF_TAB_ORDER=schedule,files,chat
# GMMFF_TAB_ORDER=files,chat,schedule
# Default tab shown on page load. If not set, the first tab in GMMFF_TAB_ORDER is used.
# Valid values: files, chat, schedule
# GMMFF_TAB_DEFAULT=
# Message of the day shown as a banner at the top of the UI.
# GMMFF_MOTD=
# ── Schedule feature ───────────────────────────────────────────────────────────
# Show the Schedule tab in the browser UI. Defaults to false.
# GMMFF_SHOW_SCHEDULE=false
# Root directory for schedule storage. Two subdirs are auto-created:
# pending/ — in-progress uploads
# complete/ — finalized uploads
# GMMFF_SCHEDULE_DIR=./data/schedule
# Maximum upload size (supports gb/mb/kb/bytes suffix). Default: 1gb.
# GMMFF_SCHEDULE_MAX_SIZE=1gb
# Server-wide cap on per-file download limits. 0 = unlimited. Default: 1.
# GMMFF_SCHEDULE_MAX_DOWNLOADS=1
# Comma-separated IP addresses/CIDRs allowed to upload without a password.
# Empty = apply password check (if set) to all IPs.
# GMMFF_SCHEDULE_UPLOAD_IP=192.168.1.0/24,10.0.0.5
# Required upload password. Empty = no password.
# If both UPLOAD_IP and PASSWORD are set: IPs in the list bypass the password.
# GMMFF_SCHEDULE_PASSWORD=
# Comma-separated IP addresses/CIDRs allowed to download.
# 0.0.0.0 or empty = anyone can download. Default: empty (allow all).
# GMMFF_SCHEDULE_DOWNLOAD_IP=0.0.0.0
# Background cleanup schedule in crontab format. Empty = no background cleanup.
# Use `gmmff cleanup` for cron-based cleanup instead.
# GMMFF_SCHEDULE_CLEANUP_INTERVAL=*/30 * * * *
# Comma-separated TTL options for the upload dropdown.
# Accepts flexible formats: "1h", "1 hour", "2 days", "2d", "1w", etc.
# Default: 1 hour, 8 hours, 1 day, 3 days, 7 days, 30 days.
# GMMFF_TTL_SETTINGS=1h,8h,1 day,3 days,7 days,30 days
# ── ICE server push ────────────────────────────────────────────────────────────
# When enabled, the server pushes its STUN/TURN config to peers before each
# session via GET /api/ice, replacing any user-defined ICE servers.
# GMMFF_PUSH_STUN=false
# GMMFF_PUSH_TURN=false
# TTL for ephemeral TURN credentials when GMMFF_PUSH_TURN=true and using secret= mode.
# Ignored when using static user/pass credentials. Default: 30m
# Accepts any Go duration: 30m, 1h, 2h30m
# GMMFF_PUSH_TTL=30m
# RECOMMENDED: when using PUSH_STUN or PUSH_TURN, also set:
# GMMFF_SHOW_ICE_SETTINGS=false — hide the ICE panel entirely
# GMMFF_ALLOW_STUN=false — prevent users from modifying STUN
# GMMFF_ALLOW_TURN=false — prevent users from modifying TURN
#
# SECURITY NOTE — TURN credentials:
# If GMMFF_TURN uses static user/pass credentials and GMMFF_PUSH_TURN=true,
# those credentials will be sent to ALL peers. Use only with public/anonymous
# TURN servers that you are comfortable exposing.
#
# If GMMFF_TURN uses a shared secret (secret= parameter), ephemeral 30-minute
# credentials are generated server-side. Only those short-lived credentials
# are sent to peers — the master secret is never exposed.