v2.30.0-pre 7341e0e

installation.md RawHistoryFolder

Installation

Detailed installation guide for production environments.

System Requirements

  • OS: Linux (Ubuntu 24.04 LTS, Debian 13 recommended) or macOS
  • Architecture: x86_64 (amd64) or ARM64
  • Memory: 512MB minimum, 1GB recommended
  • Disk: 10GB minimum for registry storage
  • Runtime: Docker or Podman

Download Gordon

curl -fsSL https://gordon.bnema.dev/install | bash

This script automatically detects your OS (Linux/macOS) and architecture (amd64/arm64), downloads the appropriate binary from GitHub releases, and installs it to /usr/local/bin.

Manual Installation

Linux (x86_64)

wget https://github.com/bnema/gordon/releases/latest/download/gordon_linux_amd64.tar.gz
tar -xzf gordon_linux_amd64.tar.gz
chmod +x gordon
sudo mv gordon /usr/local/bin/

Linux (ARM64) - for Raspberry Pi 4, AWS Graviton, Oracle Ampere, etc.

wget https://github.com/bnema/gordon/releases/latest/download/gordon_linux_arm64.tar.gz
tar -xzf gordon_linux_arm64.tar.gz
chmod +x gordon
sudo mv gordon /usr/local/bin/

macOS (Apple Silicon)

curl -LO https://github.com/bnema/gordon/releases/latest/download/gordon_darwin_arm64.tar.gz
tar -xzf gordon_darwin_arm64.tar.gz
chmod +x gordon
sudo mv gordon /usr/local/bin/

macOS (Intel)

curl -LO https://github.com/bnema/gordon/releases/latest/download/gordon_darwin_amd64.tar.gz
tar -xzf gordon_darwin_amd64.tar.gz
chmod +x gordon
sudo mv gordon /usr/local/bin/

Verify installation:

gordon version

From Source

# Requires Go 1.21+
git clone https://github.com/bnema/gordon.git
cd gordon
make build
sudo mv gordon /usr/local/bin/

Container Runtime Setup

Docker

# Install Docker
curl -fsSL https://get.docker.com | sh

# Add user to docker group
sudo usermod -aG docker $USER
newgrp docker

# Verify
docker run hello-world

Podman (Rootless)

Podman rootless mode provides enhanced security by running containers without root privileges.

# Install Podman
sudo apt update
sudo apt install -y podman

# Enable user namespaces
echo 'user.max_user_namespaces=28633' | sudo tee -a /etc/sysctl.conf
sudo sysctl -p

# Setup subuid/subgid
sudo usermod --add-subuids 100000-165535 --add-subgids 100000-165535 $USER

# Enable Podman socket
systemctl --user enable --now podman.socket

# Configure insecure localhost registry
mkdir -p ~/.config/containers
cat > ~/.config/containers/registries.conf <<EOF
[registries.insecure]
registries = ['localhost:5000']
EOF

Firewall Configuration

Gordon needs ports accessible for the registry and proxy.

Using firewalld

# Install and enable firewalld
sudo apt install -y firewalld
sudo systemctl enable --now firewalld

# Allow HTTP/HTTPS
sudo firewall-cmd --permanent --add-service=http
sudo firewall-cmd --permanent --add-service=https

# For rootless containers, redirect privileged ports
sudo firewall-cmd --permanent --add-forward-port=port=80:proto=tcp:toport=8080
sudo firewall-cmd --permanent --add-forward-port=port=443:proto=tcp:toport=8443

# Apply changes
sudo firewall-cmd --reload

# Verify
sudo firewall-cmd --list-all

Using ufw

sudo ufw allow 80/tcp
sudo ufw allow 443/tcp
sudo ufw allow 5000/tcp  # Registry port (if accessing directly)
sudo ufw enable

Configuration

Gordon creates a default configuration on first run:

# Run once to generate config, then stop
gordon serve
# Press Ctrl+C

# Edit configuration
nano ~/.config/gordon/gordon.toml

Minimum required configuration:

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

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

See Configuration Reference for all options.

Systemd Service

mkdir -p ~/.config/systemd/user
cat > ~/.config/systemd/user/gordon.service <<EOF
[Unit]
Description=Gordon Container Platform
After=podman.socket

[Service]
Type=simple
Restart=always
RestartSec=5
ExecStart=/usr/local/bin/gordon serve

[Install]
WantedBy=default.target
EOF

# Enable and start
systemctl --user daemon-reload
systemctl --user enable --now gordon

# Enable linger (keep service running after logout)
sudo loginctl enable-linger $USER

# Check status
systemctl --user status gordon

System Service (Root Mode)

sudo cat > /etc/systemd/system/gordon.service <<EOF
[Unit]
Description=Gordon Container Platform
After=docker.service
Requires=docker.service

[Service]
Type=simple
Restart=always
RestartSec=5
ExecStart=/usr/local/bin/gordon serve
User=root

[Install]
WantedBy=multi-user.target
EOF

sudo systemctl daemon-reload
sudo systemctl enable --now gordon

DNS Configuration

Point your domains to your server:

Type Name Content Proxy
A app SERVER_IP Yes (Cloudflare)
A registry SERVER_IP Yes (Cloudflare)

Note: Enable Cloudflare proxy (orange cloud) for automatic HTTPS. Gordon receives HTTP traffic from Cloudflare.

Verify Installation

# Check Gordon is running
systemctl --user status gordon

# View logs
journalctl --user -u gordon -f

# Test registry (from local machine)
docker login registry.yourdomain.com
docker pull alpine
docker tag alpine registry.yourdomain.com/test:latest
docker push registry.yourdomain.com/test:latest

Data Directories

Gordon stores data in the following locations:

Path Purpose
~/.config/gordon/gordon.toml Configuration file
~/.gordon/ Default data directory
~/.gordon/registry/ Container images
~/.gordon/env/ Environment files
~/.gordon/logs/ Application logs
~/.gordon/secrets/ Secrets (unsafe backend only)
source
1# Installation
2
3Detailed installation guide for production environments.
4
5## System Requirements
6
7- **OS**: Linux (Ubuntu 24.04 LTS, Debian 13 recommended) or macOS
8- **Architecture**: x86_64 (amd64) or ARM64
9- **Memory**: 512MB minimum, 1GB recommended
10- **Disk**: 10GB minimum for registry storage
11- **Runtime**: Docker or Podman
12
13## Download Gordon
14
15### Quick Install (Recommended)
16
17```bash
18curl -fsSL https://gordon.bnema.dev/install | bash
19```
20
21This script automatically detects your OS (Linux/macOS) and architecture (amd64/arm64), downloads the appropriate binary from GitHub releases, and installs it to `/usr/local/bin`.
22
23### Manual Installation
24
25**Linux (x86_64)**
26```bash
27wget https://github.com/bnema/gordon/releases/latest/download/gordon_linux_amd64.tar.gz
28tar -xzf gordon_linux_amd64.tar.gz
29chmod +x gordon
30sudo mv gordon /usr/local/bin/
31```
32
33**Linux (ARM64)** - for Raspberry Pi 4, AWS Graviton, Oracle Ampere, etc.
34```bash
35wget https://github.com/bnema/gordon/releases/latest/download/gordon_linux_arm64.tar.gz
36tar -xzf gordon_linux_arm64.tar.gz
37chmod +x gordon
38sudo mv gordon /usr/local/bin/
39```
40
41**macOS (Apple Silicon)**
42```bash
43curl -LO https://github.com/bnema/gordon/releases/latest/download/gordon_darwin_arm64.tar.gz
44tar -xzf gordon_darwin_arm64.tar.gz
45chmod +x gordon
46sudo mv gordon /usr/local/bin/
47```
48
49**macOS (Intel)**
50```bash
51curl -LO https://github.com/bnema/gordon/releases/latest/download/gordon_darwin_amd64.tar.gz
52tar -xzf gordon_darwin_amd64.tar.gz
53chmod +x gordon
54sudo mv gordon /usr/local/bin/
55```
56
57Verify installation:
58```bash
59gordon version
60```
61
62### From Source
63
64```bash
65# Requires Go 1.21+
66git clone https://github.com/bnema/gordon.git
67cd gordon
68make build
69sudo mv gordon /usr/local/bin/
70```
71
72## Container Runtime Setup
73
74### Docker
75
76```bash
77# Install Docker
78curl -fsSL https://get.docker.com | sh
79
80# Add user to docker group
81sudo usermod -aG docker $USER
82newgrp docker
83
84# Verify
85docker run hello-world
86```
87
88### Podman (Rootless)
89
90Podman rootless mode provides enhanced security by running containers without root privileges.
91
92```bash
93# Install Podman
94sudo apt update
95sudo apt install -y podman
96
97# Enable user namespaces
98echo 'user.max_user_namespaces=28633' | sudo tee -a /etc/sysctl.conf
99sudo sysctl -p
100
101# Setup subuid/subgid
102sudo usermod --add-subuids 100000-165535 --add-subgids 100000-165535 $USER
103
104# Enable Podman socket
105systemctl --user enable --now podman.socket
106
107# Configure insecure localhost registry
108mkdir -p ~/.config/containers
109cat > ~/.config/containers/registries.conf <<EOF
110[registries.insecure]
111registries = ['localhost:5000']
112EOF
113```
114
115## Firewall Configuration
116
117Gordon needs ports accessible for the registry and proxy.
118
119### Using firewalld
120
121```bash
122# Install and enable firewalld
123sudo apt install -y firewalld
124sudo systemctl enable --now firewalld
125
126# Allow HTTP/HTTPS
127sudo firewall-cmd --permanent --add-service=http
128sudo firewall-cmd --permanent --add-service=https
129
130# For rootless containers, redirect privileged ports
131sudo firewall-cmd --permanent --add-forward-port=port=80:proto=tcp:toport=8080
132sudo firewall-cmd --permanent --add-forward-port=port=443:proto=tcp:toport=8443
133
134# Apply changes
135sudo firewall-cmd --reload
136
137# Verify
138sudo firewall-cmd --list-all
139```
140
141### Using ufw
142
143```bash
144sudo ufw allow 80/tcp
145sudo ufw allow 443/tcp
146sudo ufw allow 5000/tcp  # Registry port (if accessing directly)
147sudo ufw enable
148```
149
150## Configuration
151
152Gordon creates a default configuration on first run:
153
154```bash
155# Run once to generate config, then stop
156gordon serve
157# Press Ctrl+C
158
159# Edit configuration
160nano ~/.config/gordon/gordon.toml
161```
162
163Minimum required configuration:
164
165```toml
166[server]
167port = 8080
168registry_port = 5000
169gordon_domain = "gordon.yourdomain.com"
170
171[routes]
172"app.yourdomain.com" = "myapp:latest"
173```
174
175See [Configuration Reference](./config/index.md) for all options.
176
177## Systemd Service
178
179### User Service (Recommended for Rootless)
180
181```bash
182mkdir -p ~/.config/systemd/user
183cat > ~/.config/systemd/user/gordon.service <<EOF
184[Unit]
185Description=Gordon Container Platform
186After=podman.socket
187
188[Service]
189Type=simple
190Restart=always
191RestartSec=5
192ExecStart=/usr/local/bin/gordon serve
193
194[Install]
195WantedBy=default.target
196EOF
197
198# Enable and start
199systemctl --user daemon-reload
200systemctl --user enable --now gordon
201
202# Enable linger (keep service running after logout)
203sudo loginctl enable-linger $USER
204
205# Check status
206systemctl --user status gordon
207```
208
209### System Service (Root Mode)
210
211```bash
212sudo cat > /etc/systemd/system/gordon.service <<EOF
213[Unit]
214Description=Gordon Container Platform
215After=docker.service
216Requires=docker.service
217
218[Service]
219Type=simple
220Restart=always
221RestartSec=5
222ExecStart=/usr/local/bin/gordon serve
223User=root
224
225[Install]
226WantedBy=multi-user.target
227EOF
228
229sudo systemctl daemon-reload
230sudo systemctl enable --now gordon
231```
232
233## DNS Configuration
234
235Point your domains to your server:
236
237| Type | Name | Content | Proxy |
238|------|------|---------|-------|
239| A | `app` | `SERVER_IP` | Yes (Cloudflare) |
240| A | `registry` | `SERVER_IP` | Yes (Cloudflare) |
241
242> **Note:** Enable Cloudflare proxy (orange cloud) for automatic HTTPS. Gordon receives HTTP traffic from Cloudflare.
243
244## Verify Installation
245
246```bash
247# Check Gordon is running
248systemctl --user status gordon
249
250# View logs
251journalctl --user -u gordon -f
252
253# Test registry (from local machine)
254docker login registry.yourdomain.com
255docker pull alpine
256docker tag alpine registry.yourdomain.com/test:latest
257docker push registry.yourdomain.com/test:latest
258```
259
260## Data Directories
261
262Gordon stores data in the following locations:
263
264| Path | Purpose |
265|------|---------|
266| `~/.config/gordon/gordon.toml` | Configuration file |
267| `~/.gordon/` | Default data directory |
268| `~/.gordon/registry/` | Container images |
269| `~/.gordon/env/` | Environment files |
270| `~/.gordon/logs/` | Application logs |
271| `~/.gordon/secrets/` | Secrets (unsafe backend only) |
272
273## Related
274
275- [Getting Started](./getting-started.md)
276- [Configuration Reference](./config/index.md)
277- [Podman Rootless Setup](/wiki/guides/podman-rootless.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