Install Florabase
Florabase is installed with one directly usable compose.yaml file and three published linux/amd64 non-root container images (ghcr.io/alessandrorossato/florabase-*). No .env file is required, no container runs as root, and building from source is for development only.
Prerequisites
Section titled “Prerequisites”linux/amd64Docker host with Docker Engine 24+ and Docker Compose 2.20+ (other CPU architectures such asarm64are not built in v1.0.0).- Compose manager or CLI: Docker CLI (
docker compose), Dockhand, or Synology Container Manager. - Two separate local host folders inside a mounted volume (never at the volume mountpoint itself): one for data and one for backups.
- Dedicated HTTPS hostname served at the root path
/via a reverse proxy or Tailscale Serve (subpath hosting is not supported). - Pull access to GHCR (
ghcr.io/alessandrorossato/florabase-*) and private off-host storage for encrypted backups.
What gets installed
Section titled “What gets installed”| Service | Container (UID:GID) |
Role |
|---|---|---|
db |
florabase-db (70:70) |
PostgreSQL 18 (florabase-postgres:latest). Refuses placeholder passwords, validates folder ownership/modes and cluster identity before starting, pins session timezone to UTC. |
backend |
florabase-backend (10001:10001) |
Runs florabase-start: validates mount separation, runs guarded initialization or verified pre-upgrade dump + migration, creates optional first owner, scrubs owner variables, then execs the API server. |
frontend |
florabase-frontend (101:101) |
Static web app + reverse proxy to backend. Publishes the only host port on 127.0.0.1:8080. |
Step 1: Create the host folders and set owners once
Section titled “Step 1: Create the host folders and set owners once”Run this block as root (or with sudo) on the Docker host before your first deploy. Adjust DATA and BACKUP to real paths inside a local ext4/Btrfs volume. If any folder is missing or has the wrong owner/mode, db and backend refuse to start instead of silently creating an empty database on the wrong disk.
DATA=/srv/florabase/dataBACKUP=/srv/florabase/backup
mkdir -p "$DATA/postgres" "$DATA/media" "$DATA/state" "$BACKUP/pre-upgrade"chmod a+rx "$DATA" && chmod a+x "$BACKUP"chown 70:70 "$DATA/postgres" && chmod 0700 "$DATA/postgres"chown 10001:10001 "$DATA/media" "$DATA/state" "$BACKUP/pre-upgrade"chmod 0700 "$DATA/media" "$BACKUP/pre-upgrade" && chmod 0755 "$DATA/state"Step 2: Download and edit compose.yaml
Section titled “Step 2: Download and edit compose.yaml”Download compose.yaml directly from the latest release tag on GitHub (example using a pinned tag):
TAG=v1.0.0curl -fsSLO "https://raw.githubusercontent.com/alessandrorossato/florabase/${TAG}/compose.yaml"Generate a strong database password:
openssl rand -hex 32Edit these fields directly in compose.yaml (or inside Dockhand / Container Manager):
| Field | Required | Meaning |
|---|---|---|
Host bind paths (left side of :) |
Yes | Absolute host paths for DATA (identical on db and backend) and separate BACKUP (on backend). Change only the left side of each mount. |
FLORABASE_DB_PASSWORD |
Yes | PostgreSQL password — must match identically in db and backend. Both refuse to start while it is change-me. |
FLORABASE_CANONICAL_ORIGIN |
Yes | Your exact HTTPS origin (e.g. https://florabase.example.com) with no trailing slash or path. Refuses the default placeholder https://florabase.example.org. |
frontend port |
No | Loopback binding, default 127.0.0.1:8080:8080. Keep the 127.0.0.1: prefix. |
TZ |
No | IANA timezone for container logs (release compose.yaml defaults to Europe/Rome; change to UTC or your local timezone). Database storage and sessions always stay in UTC. |
FLORABASE_OWNER_LOGIN |
First run only | Uncomment to create the initial owner (3–64 lowercase letters, digits, ., _, -). |
FLORABASE_OWNER_PASSWORD |
First run only | Uncomment to set the initial owner password (at least 12 characters). |
Step 3: Deploy the stack
Section titled “Step 3: Deploy the stack”docker compose --project-name florabase up -d --waitOn first start, db creates the PostgreSQL cluster, backend initializes the schema, writes state/installation.env, creates the initial owner (if configured), and starts serving.
- Did not set
FLORABASE_OWNER_*? The stack still starts cleanly; create the owner offline via:Terminal window docker compose --project-name florabase run --rm --no-deps backend \python -m florabase.auth.bootstrap owner - Docker Engine 24 note: Engine 24 ignores
start-interval, so a cold start can take up to 30 seconds per service in thedb → backend → frontendchain. Engine 25+ starts in a few seconds.
Step 4: Expose over HTTPS and sign in
Section titled “Step 4: Expose over HTTPS and sign in”Florabase only listens on 127.0.0.1:8080. Put it behind an HTTPS reverse proxy or Tailscale Serve before signing in:
- Continue to Reverse Proxy (HTTPS & Tailscale).
After your first sign-in:
- Remove
FLORABASE_OWNER_LOGINandFLORABASE_OWNER_PASSWORDfromcompose.yaml(and your Compose manager UI) and redeploy so credentials do not remain indocker inspector manager exports. - Change your owner password from Settings → Account.
- Set up scheduled Backup, Restore & Upgrades.
Next steps in Self-Hosting
Section titled “Next steps in Self-Hosting”- Reverse Proxy (HTTPS & Tailscale) — Nginx, Tailscale Serve, and Synology NAS notes
- Backup, Restore & Upgrades — paired DB + media backups and safe upgrades
- Reference Data (WFO & WCVP) — optional local taxonomy & native range indexes
- Troubleshooting & Recovery — startup refusals and offline password reset