Fleetdock

Manager installation

Install and operate the Fleetdock Manager control plane with Docker Compose, TLS, persistent storage, and production configuration.

The Fleetdock Manager is the control plane. This page covers installing it, the environment variables it reads, and how to run it safely in production.

System requirements

Fleet sizeSuggested host
1–10 servers2 vCPU, 4 GB RAM
10–50 servers4 vCPU, 8 GB RAM
50+ serversDedicated database + API host

You also need Docker Engine 24+ and Docker Compose v2.23+, with ports 80 and 443 free. TLS is handled for you by the bundled Caddy, which obtains a Let's Encrypt certificate automatically — a domain pointed at the host is optional but recommended.

Database requirements

The Manager stores metadata in PostgreSQL. The Compose stack bundles a local Postgres container for development. In production, point FLEETDOCK_DATABASE_URL at managed PostgreSQL (Neon, RDS, Cloud SQL, or any PostgreSQL 14+) with sslmode=require.

Install

curl -sSL https://fleetdock.dev/install.sh | sh -s -- --domain db.example.com

This installs Docker if missing, writes /opt/fleetdock/{docker-compose.yml,.env} with generated secrets, starts the stack, and prints the dashboard URL and bootstrap password. Re-running it upgrades in place without touching .env.

Manage it afterwards with the fleetdock command it installs — status, logs, update, domain, gateway, doctor, backup-config, uninstall.

From source

Configure

git clone https://github.com/Fleetdock/fleetdock.git
cd fleetdock
cp .env.example .env
./scripts/generate-secrets.sh >> .env

Set FLEETDOCK_DOMAIN, FLEETDOCK_SITE_ADDRESS and FLEETDOCK_PUBLIC_URL to your hostname.

Start

docker compose -f docker-compose.yml -f docker-compose.build.yml up --build -d

Drop the overlay to run the published image instead of building it. For managed PostgreSQL, point FLEETDOCK_DATABASE_URL at it and scale the bundled one away with --scale postgres=0.

Environment variables

Variables use the FLEETDOCK_* prefix. The most important ones:

VariableDefaultNotes
FLEETDOCK_DATABASE_URLRequired. PostgreSQL connection string.
FLEETDOCK_ENVdevelopmentproduction refuses to start with default secrets.
FLEETDOCK_HTTP_ADDR:8080Listen address for the API and dashboard.
FLEETDOCK_DOMAINThe one hostname everything else is derived from.
FLEETDOCK_SITE_ADDRESSCaddy site address. A bare host gets automatic TLS; http://… serves plain HTTP.
FLEETDOCK_JWT_SECRETdev defaultSet a strong secret in production.
FLEETDOCK_ENCRYPTION_KEYdev defaultEncrypts credentials and storage keys at rest.
FLEETDOCK_PUBLIC_URLhttp://localhost:8080URL agents and installers use to reach the API.
FLEETDOCK_CORS_ORIGINhttp://localhost:3000Only used for split-origin deployments; a normal same-origin install never hits CORS.
FLEETDOCK_TRUST_PROXY_HEADERSfalseTrust X-Forwarded-For for login rate limiting. Set only when the API is reachable solely through a proxy.
FLEETDOCK_HEARTBEAT_TIMEOUT2mNo heartbeat for this long ⇒ node offline.
FLEETDOCK_METRICS_RETENTION168hHow long per-heartbeat metrics are kept.
FLEETDOCK_GATEWAY_ENABLEDfalseEnable the Fleetdock Gateway (HAProxy) service.
FLEETDOCK_GATEWAY_PUBLIC_HOSTFLEETDOCK_DOMAINHostname external apps use to reach the gateway. Defaults to your main domain.
FLEETDOCK_GATEWAY_PORT_RANGE_START15432First port in the gateway's public port range.
FLEETDOCK_GATEWAY_PORT_RANGE_END15481Last port in the gateway's public port range.
FLEETDOCK_GATEWAY_DIAG_PORT15431Reports the source address the gateway observes. 0 disables.
FLEETDOCK_GATEWAY_SOURCE_IP_MODEdirectdirect or proxy-protocol (behind an L4 load balancer).
FLEETDOCK_GATEWAY_CONFIG_PATH/var/lib/fleetdock/gateway/haproxy.cfgHAProxy config path.
FLEETDOCK_GATEWAY_MASTER_SOCKET/var/lib/fleetdock/gateway/haproxy-master.sockHAProxy master socket for hitless reload.
FLEETDOCK_GATEWAY_ADMIN_SOCKET/var/lib/fleetdock/gateway/haproxy-admin.sockHAProxy stats socket, used to read endpoint health.

There is no API URL to configure for the dashboard. It calls the API on whatever origin serves it, so the published image works unmodified on any hostname and changing your domain never requires a rebuild.

See .env.example in the repository for the full list, including optional SMTP variables for email notifications and gateway configuration for external database access.

HTTPS and reverse proxy

The stack ships Caddy on 80/443 with automatic certificates, so there is nothing to set up. Nothing else is published — the control plane's 8080 stays on the internal network.

If you replace it with your own proxy, there is no path routing to reproduce: the control plane serves the API and the dashboard on one port, so a single upstream is the whole config.

db.example.com {
    encode zstd gzip
    reverse_proxy fleetdock:8080
}

Keep FLEETDOCK_TRUST_PROXY_HEADERS=true only while the API is reachable solely through the proxy. If port 8080 is also exposed, a client can spoof X-Forwarded-For and bypass the login rate limiter.

Persistent storage

The bundled Postgres writes to a Docker named volume (postgres_data). In production, your managed PostgreSQL provider is the source of truth — the metadata database holds users, server enrollment, encrypted credentials, backup destinations, and job history. Losing it without a backup means re-enrolling every server and re-entering every external credential.

Verify

curl -fsS https://db.example.com/healthz    # {"status":"ok"}
curl -fsS https://db.example.com/readyz     # {"status":"ready"} once the DB is up

Then sign in and change the bootstrap admin password on the Profile page. Interactive API docs are also available on this site under API reference (with an interactive playground). The Manager itself serves Redoc at /docs over the embedded OpenAPI spec.

Update

fleetdock update              # latest
fleetdock update --tag v0.2.0 # a specific release

Or, from a source checkout:

git fetch origin && git checkout v0.2.0
docker compose -f docker-compose.yml -f docker-compose.build.yml up --build -d

Migrations run automatically on API start. Confirm GET /readyz returns ready, then spot -check login and a connection test. Watch the Operations page for stuck jobs after an upgrade.

Before upgrading, back up the metadata PostgreSQL database. If a migration has already advanced the schema, roll back by restoring that database, not just the API binary.

Uninstall

docker compose down          # stop containers, keep the database volume
docker compose down -v       # also delete volumes — destroys the metadata database

docker compose down -v deletes the postgres_data volume and permanently removes all Fleetdock metadata. Only run it if you intend to discard the installation.

On this page