v2.16.0 ebd2ab3

index.md RawHistoryFolder

Configuration Overview

Gordon uses a single TOML configuration file located at ~/.config/gordon/gordon.toml.

Configuration File Location

Location Purpose
~/.config/gordon/gordon.toml Default configuration file
Custom path via --config flag gordon serve --config /path/to/config.toml

Minimal Configuration

[server]
port = 8080
registry_port = 5000
gordon_domain = "gordon.mydomain.com"

[routes]
"app.mydomain.com" = "myapp:latest"

Full Configuration Reference

For a complete list of all configuration options with their default values, see the Configuration Reference.

Note: This example shows production-style paths. Default paths use ~/.gordon/ for user installations.

# Server settings
[server]
port = 8080                              # HTTP proxy port (default: 80)
registry_port = 5000                     # Registry port (default: 5000)
gordon_domain = "gordon.mydomain.com"    # Required: Gordon domain (registry + API)
# data_dir = "~/.gordon"                 # Default for user installations

# Authentication (includes secrets backend)
[auth]
enabled = true                           # Enable registry authentication (default: true)
secrets_backend = "pass"                 # "pass", "sops", or "unsafe"
token_secret = "gordon/auth/token_secret"  # Required: JWT signing secret
token_expiry = "30d"                     # Duration (1y, 30d, 2w) or 0 for never
# Optional: enable password authentication (for interactive login)
# username = "deploy"
# password_hash = "gordon/auth/password_hash"

# API rate limiting
[api.rate_limit]
enabled = true                           # Enable rate limiting (default: true)
global_rps = 500                         # Max requests/second globally
per_ip_rps = 50                          # Max requests/second per IP
burst = 100                              # Burst size
trusted_proxies = []                     # IPs/CIDRs trusted for X-Forwarded-For

# Deploy behavior
[deploy]
pull_policy = "if-tag-changed"           # always, if-not-present, if-tag-changed
readiness_mode = "auto"                  # auto, docker-health, delay
health_timeout = "90s"                   # Max wait for health-based readiness
readiness_delay = "5s"                   # Wait after running before ready
drain_mode = "auto"                      # auto, inflight, delay
drain_timeout = "30s"                    # Max wait for in-flight drain
drain_delay = "2s"                       # Wait after proxy invalidation before stopping the old container

# Logging
[logging]
level = "info"                           # trace, debug, info, warn, error
format = "console"                       # console or json

[logging.file]
enabled = true
path = "~/.gordon/logs/gordon.log"       # Default location
max_size = 100                           # MB before rotation
max_backups = 3                          # Old files to keep
max_age = 28                             # Days to keep

[logging.container_logs]
enabled = true
dir = "~/.gordon/logs/containers"        # Default location
max_size = 100
max_backups = 3
max_age = 28

# Telemetry (OpenTelemetry)
[telemetry]
enabled = true                           # Enable OTLP export (default: false)
endpoint = "http://localhost:5080/api/default"  # OTLP HTTP endpoint
auth_token = ""                          # Base64 user:password for Basic auth
traces = true                            # Export traces
metrics = true                           # Export metrics
logs = true                              # Bridge zerolog to OTLP logs
trace_sample_rate = 1.0                  # 0.0 = none, 1.0 = all

# Environment variables
[env]
dir = "~/.gordon/env"                    # Default location

# Volume settings
[volumes]
auto_create = true                       # Auto-create from Dockerfile VOLUME
prefix = "gordon"                        # Volume name prefix
preserve = true                          # Keep volumes on container removal

# Network isolation
[network_isolation]
enabled = true                           # Per-app isolated networks
network_prefix = "gordon"                # Network name prefix
dns_suffix = ".internal"                 # DNS suffix for services

# Auto-route
[auto_route]
enabled = false                          # Auto-create routes from image names

# Routes (required)
[routes]
"app.mydomain.com" = "myapp:latest"
"api.mydomain.com" = "myapi:v2.1.0"

# Network groups
[network_groups]
"backend" = ["app.mydomain.com", "api.mydomain.com"]

# Attachments
[attachments]
"app.mydomain.com" = ["postgres:latest", "redis:latest"]
"backend" = ["rabbitmq:latest"]

# Backups
[backups]
enabled = true
schedule = "daily"                        # "hourly", "daily", "weekly", "monthly"
storage_dir = "~/.gordon/backups"

[backups.retention]
hourly = 24
daily = 7
weekly = 4
monthly = 12

# Images
[images.prune]
enabled = false
schedule = "daily"
keep_last = 3

Configuration Sections

Section Description Documentation
[server] Core server settings Server
[auth] Authentication and secrets backend Auth
[api.rate_limit] Rate limiting configuration Rate Limiting
[deploy] Deployment behavior Deploy
[logging] Logging configuration Logging
[telemetry] OpenTelemetry observability export Telemetry
[env] Environment variable settings Environment
[volumes] Volume management Volumes
[network_isolation] Network isolation settings Network Isolation
[auto_route] Automatic route creation Auto Route
[routes] Domain to image mapping Routes
[external_routes] Non-containerized service proxying External Routes
[network_groups] Shared service networks Network Groups
[attachments] Service dependencies Attachments
[backups] Database backups Backups
[images.prune] Scheduled image cleanup Images

Default Values

Setting Default
server.port 80
server.registry_port 5000
server.data_dir ~/.gordon
auth.enabled true
auth.secrets_backend "unsafe"
auth.token_expiry "30d"
api.rate_limit.enabled true
api.rate_limit.global_rps 500
api.rate_limit.per_ip_rps 50
api.rate_limit.burst 100
api.rate_limit.trusted_proxies []
deploy.pull_policy "if-tag-changed"
deploy.readiness_mode "auto"
deploy.health_timeout "90s"
deploy.readiness_delay "5s"
deploy.drain_mode "auto"
deploy.drain_timeout "30s"
deploy.drain_delay "2s"
logging.level "info"
logging.format "console"
logging.file.enabled false
logging.file.max_size 100
logging.file.max_backups 3
logging.file.max_age 28
logging.container_logs.enabled true
volumes.auto_create true
volumes.prefix "gordon"
volumes.preserve true
network_isolation.enabled false
auto_route.enabled false
backups.enabled false
backups.schedule "daily" ("hourly", "daily", "weekly", "monthly")
images.prune.enabled false
images.prune.schedule "daily"
images.prune.keep_last 3
telemetry.enabled false
telemetry.endpoint ""
telemetry.auth_token ""
telemetry.traces true
telemetry.metrics true
telemetry.logs true
telemetry.trace_sample_rate 1.0

When auth.enabled=false, Gordon runs in local-only mode: /admin/* is disabled and /v2/* is loopback-only.

Hot Reload

Gordon watches the configuration file and reloads automatically when changes are detected. You can also trigger a manual reload:

gordon reload

The following settings require a restart to take effect:

  • server.port
  • server.registry_port
  • server.data_dir
  • auth settings
  • deploy.pull_policy
  • deploy.readiness_mode
  • deploy.health_timeout
  • deploy.readiness_delay
  • deploy.drain_mode
  • deploy.drain_timeout
  • deploy.drain_delay

Environment Variable Override

Configuration values can be overridden with environment variables:

GORDON_SERVER_PORT=8080 gordon serve
GORDON_LOGGING_LEVEL=debug gordon serve

Pattern: GORDON_SECTION_KEY (uppercase, underscores instead of dots)

source
1# Configuration Overview
2
3Gordon uses a single TOML configuration file located at `~/.config/gordon/gordon.toml`.
4
5## Configuration File Location
6
7| Location | Purpose |
8|----------|---------|
9| `~/.config/gordon/gordon.toml` | Default configuration file |
10| Custom path via `--config` flag | `gordon serve --config /path/to/config.toml` |
11
12## Minimal Configuration
13
14```toml
15[server]
16port = 8080
17registry_port = 5000
18gordon_domain = "gordon.mydomain.com"
19
20[routes]
21"app.mydomain.com" = "myapp:latest"
22```
23
24## Full Configuration Reference
25
26For a complete list of all configuration options with their default values, see the [Configuration Reference](./reference.md).
27
28> **Note:** This example shows production-style paths. Default paths use `~/.gordon/` for user installations.
29
30```toml
31# Server settings
32[server]
33port = 8080                              # HTTP proxy port (default: 80)
34registry_port = 5000                     # Registry port (default: 5000)
35gordon_domain = "gordon.mydomain.com"    # Required: Gordon domain (registry + API)
36# data_dir = "~/.gordon"                 # Default for user installations
37
38# Authentication (includes secrets backend)
39[auth]
40enabled = true                           # Enable registry authentication (default: true)
41secrets_backend = "pass"                 # "pass", "sops", or "unsafe"
42token_secret = "gordon/auth/token_secret"  # Required: JWT signing secret
43token_expiry = "30d"                     # Duration (1y, 30d, 2w) or 0 for never
44# Optional: enable password authentication (for interactive login)
45# username = "deploy"
46# password_hash = "gordon/auth/password_hash"
47
48# API rate limiting
49[api.rate_limit]
50enabled = true                           # Enable rate limiting (default: true)
51global_rps = 500                         # Max requests/second globally
52per_ip_rps = 50                          # Max requests/second per IP
53burst = 100                              # Burst size
54trusted_proxies = []                     # IPs/CIDRs trusted for X-Forwarded-For
55
56# Deploy behavior
57[deploy]
58pull_policy = "if-tag-changed"           # always, if-not-present, if-tag-changed
59readiness_mode = "auto"                  # auto, docker-health, delay
60health_timeout = "90s"                   # Max wait for health-based readiness
61readiness_delay = "5s"                   # Wait after running before ready
62drain_mode = "auto"                      # auto, inflight, delay
63drain_timeout = "30s"                    # Max wait for in-flight drain
64drain_delay = "2s"                       # Wait after proxy invalidation before stopping the old container
65
66# Logging
67[logging]
68level = "info"                           # trace, debug, info, warn, error
69format = "console"                       # console or json
70
71[logging.file]
72enabled = true
73path = "~/.gordon/logs/gordon.log"       # Default location
74max_size = 100                           # MB before rotation
75max_backups = 3                          # Old files to keep
76max_age = 28                             # Days to keep
77
78[logging.container_logs]
79enabled = true
80dir = "~/.gordon/logs/containers"        # Default location
81max_size = 100
82max_backups = 3
83max_age = 28
84
85# Telemetry (OpenTelemetry)
86[telemetry]
87enabled = true                           # Enable OTLP export (default: false)
88endpoint = "http://localhost:5080/api/default"  # OTLP HTTP endpoint
89auth_token = ""                          # Base64 user:password for Basic auth
90traces = true                            # Export traces
91metrics = true                           # Export metrics
92logs = true                              # Bridge zerolog to OTLP logs
93trace_sample_rate = 1.0                  # 0.0 = none, 1.0 = all
94
95# Environment variables
96[env]
97dir = "~/.gordon/env"                    # Default location
98
99# Volume settings
100[volumes]
101auto_create = true                       # Auto-create from Dockerfile VOLUME
102prefix = "gordon"                        # Volume name prefix
103preserve = true                          # Keep volumes on container removal
104
105# Network isolation
106[network_isolation]
107enabled = true                           # Per-app isolated networks
108network_prefix = "gordon"                # Network name prefix
109dns_suffix = ".internal"                 # DNS suffix for services
110
111# Auto-route
112[auto_route]
113enabled = false                          # Auto-create routes from image names
114
115# Routes (required)
116[routes]
117"app.mydomain.com" = "myapp:latest"
118"api.mydomain.com" = "myapi:v2.1.0"
119
120# Network groups
121[network_groups]
122"backend" = ["app.mydomain.com", "api.mydomain.com"]
123
124# Attachments
125[attachments]
126"app.mydomain.com" = ["postgres:latest", "redis:latest"]
127"backend" = ["rabbitmq:latest"]
128
129# Backups
130[backups]
131enabled = true
132schedule = "daily"                        # "hourly", "daily", "weekly", "monthly"
133storage_dir = "~/.gordon/backups"
134
135[backups.retention]
136hourly = 24
137daily = 7
138weekly = 4
139monthly = 12
140
141# Images
142[images.prune]
143enabled = false
144schedule = "daily"
145keep_last = 3
146```
147
148## Configuration Sections
149
150| Section | Description | Documentation |
151|---------|-------------|---------------|
152| `[server]` | Core server settings | [Server](./server.md) |
153| `[auth]` | Authentication and secrets backend | [Auth](./auth.md) |
154| `[api.rate_limit]` | Rate limiting configuration | [Rate Limiting](./rate-limiting.md) |
155| `[deploy]` | Deployment behavior | [Deploy](./deploy.md) |
156| `[logging]` | Logging configuration | [Logging](./logging.md) |
157| `[telemetry]` | OpenTelemetry observability export | [Telemetry](./telemetry.md) |
158| `[env]` | Environment variable settings | [Environment](./env.md) |
159| `[volumes]` | Volume management | [Volumes](./volumes.md) |
160| `[network_isolation]` | Network isolation settings | [Network Isolation](./network-isolation.md) |
161| `[auto_route]` | Automatic route creation | [Auto Route](./auto-route.md) |
162| `[routes]` | Domain to image mapping | [Routes](./routes.md) |
163| `[external_routes]` | Non-containerized service proxying | [External Routes](./external-routes.md) |
164| `[network_groups]` | Shared service networks | [Network Groups](./network-groups.md) |
165| `[attachments]` | Service dependencies | [Attachments](./attachments.md) |
166| `[backups]` | Database backups | [Backups](./backups.md) |
167| `[images.prune]` | Scheduled image cleanup | [Images](./images.md) |
168
169## Default Values
170
171| Setting | Default |
172|---------|---------|
173| `server.port` | `80` |
174| `server.registry_port` | `5000` |
175| `server.data_dir` | `~/.gordon` |
176| `auth.enabled` | `true` |
177| `auth.secrets_backend` | `"unsafe"` |
178| `auth.token_expiry` | `"30d"` |
179| `api.rate_limit.enabled` | `true` |
180| `api.rate_limit.global_rps` | `500` |
181| `api.rate_limit.per_ip_rps` | `50` |
182| `api.rate_limit.burst` | `100` |
183| `api.rate_limit.trusted_proxies` | `[]` |
184| `deploy.pull_policy` | `"if-tag-changed"` |
185| `deploy.readiness_mode` | `"auto"` |
186| `deploy.health_timeout` | `"90s"` |
187| `deploy.readiness_delay` | `"5s"` |
188| `deploy.drain_mode` | `"auto"` |
189| `deploy.drain_timeout` | `"30s"` |
190| `deploy.drain_delay` | `"2s"` |
191| `logging.level` | `"info"` |
192| `logging.format` | `"console"` |
193| `logging.file.enabled` | `false` |
194| `logging.file.max_size` | `100` |
195| `logging.file.max_backups` | `3` |
196| `logging.file.max_age` | `28` |
197| `logging.container_logs.enabled` | `true` |
198| `volumes.auto_create` | `true` |
199| `volumes.prefix` | `"gordon"` |
200| `volumes.preserve` | `true` |
201| `network_isolation.enabled` | `false` |
202| `auto_route.enabled` | `false` |
203| `backups.enabled` | `false` |
204| `backups.schedule` | `"daily"` (`"hourly"`, `"daily"`, `"weekly"`, `"monthly"`) |
205| `images.prune.enabled` | `false` |
206| `images.prune.schedule` | `"daily"` |
207| `images.prune.keep_last` | `3` |
208| `telemetry.enabled` | `false` |
209| `telemetry.endpoint` | `""` |
210| `telemetry.auth_token` | `""` |
211| `telemetry.traces` | `true` |
212| `telemetry.metrics` | `true` |
213| `telemetry.logs` | `true` |
214| `telemetry.trace_sample_rate` | `1.0` |
215
216When `auth.enabled=false`, Gordon runs in local-only mode: `/admin/*` is disabled and `/v2/*` is loopback-only.
217
218## Hot Reload
219
220Gordon watches the configuration file and reloads automatically when changes are detected. You can also trigger a manual reload:
221
222```bash
223gordon reload
224```
225
226The following settings require a restart to take effect:
227
228- `server.port`
229- `server.registry_port`
230- `server.data_dir`
231- `auth` settings
232- `deploy.pull_policy`
233- `deploy.readiness_mode`
234- `deploy.health_timeout`
235- `deploy.readiness_delay`
236- `deploy.drain_mode`
237- `deploy.drain_timeout`
238- `deploy.drain_delay`
239
240## Environment Variable Override
241
242Configuration values can be overridden with environment variables:
243
244```bash
245GORDON_SERVER_PORT=8080 gordon serve
246GORDON_LOGGING_LEVEL=debug gordon serve
247```
248
249Pattern: `GORDON_SECTION_KEY` (uppercase, underscores instead of dots)
250
251## Related
252
253- [Server Configuration](./server.md)
254- [Routes Configuration](./routes.md)
255- [External Routes](./external-routes.md)
256- [Authentication](./auth.md)
257- [Telemetry](./telemetry.md)
258- [Backups](./backups.md)
259- [Images](./images.md)

Keyboard shortcuts

Single-key shortcuts are on. ctrl k and esc work whatever this says.

ctrl k :
go to a section, branch, tag, file or repository
?
this list
j k
move the row cursor down / up
enter
open the row under the cursor; on Files, a directory opens or closes in place
↑ ↓ ← → home end
in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
l h
on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. Elsewhere: into the side panel (on a merge request, its files) / back to the content; there j k move between its controls
g g G
first / last row
/
filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
b
switch branch or tag
g s g f g c g b g m g i g r g a
tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
g h
home
w
wide mode: use the whole width of the screen, or not (remembered)
y
copy a permalink pinned to the commit
d u x
diff: split / unified / collapse or expand all
e E
diff: the whole file in view / every file, with the lines the hunks hide
n
merge request: next note in the diff
esc
close a dialog, leave a field

Branches 7

Tags 106

↑↓ moveenter openesc close