Fleetdock

Getting started

Go from zero to your first managed database instance — install the Manager, connect a server, and provision MariaDB, MySQL, or PostgreSQL.

This guide takes you from nothing to a running, backed-up database instance managed by Fleetdock. It uses the real commands from the repository. The example provisions MariaDB; the same steps apply to MySQL and PostgreSQL.

Prerequisites

  • A Linux host for the Manager (x86_64 or arm64). Docker is installed for you if missing.
  • Ports 80 and 443 free on that host.
  • Optionally a domain pointed at it — without one, Fleetdock uses an <ip>.sslip.io name that still gets a real TLS certificate.
  • One or more Linux database servers you can run a command on as root.
  • Outbound internet from those servers (to download the agent and, optionally, back up to object storage).

1. Install Fleetdock Manager

Server or your own computer? This guide installs the Manager on a server, so your database servers can connect to it. To run Fleetdock only on your own machine — macOS, Linux, or Windows through WSL2 — follow Install on your computer instead.

On the server, run:

curl -sSL https://fleetdock.dev/install.sh | sudo sh

It asks three things:

  1. Where are you installing? Press Enter for a server.
  2. Domain — the hostname you pointed at this server, or press Enter for a free <ip>.sslip.io name that still gets a real HTTPS certificate.
  3. Admin email.

It then shows a summary and waits for you to confirm. It installs Docker if needed, generates secrets, starts the stack behind Caddy with automatic HTTPS, and prints:

  Fleetdock is running.

    Dashboard   https://db.example.com
    Email       [email protected]
    Password    8fK2mQ...

The stack runs one application container plus PostgreSQL and Caddy. Only 80 and 443 are published. Migrations are applied and the admin account bootstrapped on first boot.

For automation, give the answers as flags and skip the questions:

curl -sSL https://fleetdock.dev/install.sh | sudo sh -s -- \
  --domain db.example.com --admin-email [email protected] --yes

Re-running the installer upgrades in place and never regenerates .env — rotating FLEETDOCK_ENCRYPTION_KEY would make every stored credential permanently unreadable. Use fleetdock update for routine upgrades.

Managing the install

The installer also adds a fleetdock command on the host:

fleetdock status                  # container health and readiness
fleetdock credentials             # dashboard URL and admin login
fleetdock logs -f
fleetdock update                  # back up, then pull a new release and restart
fleetdock domain new.example.com  # move to a different hostname
fleetdock doctor                  # diagnose DNS, certificates, reachability

Running from source instead

To work on Fleetdock itself, see CONTRIBUTING.md:

git clone https://github.com/Fleetdock/fleetdock.git
cd fleetdock
cp .env.example .env
./scripts/generate-secrets.sh >> .env
make up        # the full stack in Docker, at http://localhost

2. Create an administrator account

The first admin is created on first boot with the email and password the installer printed (fleetdock credentials shows them again). Sign in, then change the password: your name (top right) → Your profile.

3. Add a node and generate a registration token

In the dashboard, open Servers → Connect server. Fleetdock generates a single-use registration token (prefix fleetr_) and a ready-to-paste install command.

Registration tokens are single-use and short-lived. Never paste a real token into a chat, an issue, or a public channel. The examples in these docs use a placeholder.

4. Install the Fleetdock Agent

Run the generated command on the database server. This is the agent installer, served by your own Manager — not fleetdock.dev/install.sh, which installs the Manager. Put sudo after the pipe (before sh), because the installer must run as root:

curl -sSL https://your-control-plane/install.sh | \
  sudo env FLEETDOCK_URL=https://your-control-plane \
           FLEETDOCK_TOKEN=<registration-token> sh

The installer downloads the agent binary from the control plane, installs the MariaDB and PostgreSQL client tools, ensures Docker is present, and starts a systemd service.

5. Verify node connectivity

The server appears in Servers within about 30 seconds and then heartbeats every 30 seconds. On the server itself you can confirm the service is running:

systemctl status fleetdock-agent

For local VM development, set FLEETDOCK_PUBLIC_URL to an address the VM can actually reach (for example http://192.168.x.x), not localhost — it is baked into the install command each agent is given. See Networking.

6. Provision your first database instance

Open Servers → your server → Add instance → Provision new and pick an engine — MariaDB, MySQL, or PostgreSQL. Fleetdock launches a database container with a generated superuser password, a named data volume, and a published port. See Database instances for the configuration fields.

7. Configure backups

Add a backup destination

Under Destinations, add an S3, Cloudflare R2, or S3-compatible bucket and run Test bucket. Storage keys are encrypted at rest.

Back up a database

From a database's detail page, trigger a manual backup, or create a recurring Schedule with a retention window.

8. Verify database connectivity

Provisioned instances publish a port on the server. Connect with your engine's client using the generated credentials shown in the instance details:

# MariaDB / MySQL
mariadb -h <server-address> -P <published-port> -u <user> -p

# PostgreSQL
psql "postgresql://<user>@<server-address>:<published-port>/<database>"

Where to go next

  • Core concepts — the vocabulary behind servers, instances, and operations.
  • Backups and Restore — protect and recover data.
  • Security — the trust model and hardening steps before production.

On this page