Deploy with Docker Compose
This is the standard way to self-host: one app container and one Postgres container on a Linux server, behind a reverse proxy that handles HTTPS.
Before you start
Section titled “Before you start”- A server with Docker and Docker Compose (1 GB of RAM is enough).
- A domain name pointing at the server, such as
tasks.example.com. - A reverse proxy for HTTPS, such as Caddy, Traefik or nginx. Reverse proxy and client IPs has a Caddy example.
Install
Section titled “Install”Follow Try it with Docker Compose on the server, with one change: set BETTER_AUTH_URL to your public URL.
BETTER_AUTH_URL=https://tasks.example.comThis must be the exact URL people type, with https and no trailing path. Sign-in only accepts requests from this origin (plus any in TRUSTED_ORIGINS).
Choose how to create the admin
Section titled “Choose how to create the admin”You have two options:
- Setup token (default): start the app, run
docker compose logs app | grep setup_token=, and open your URL. See First-run setup. - Environment variables: set
ADMIN_EMAILandADMIN_PASSWORD(orADMIN_PASSWORD_FILE) in.envbefore the first start. The admin is created at startup and the setup page is skipped.
Start and check it
Section titled “Start and check it”docker compose up -ddocker compose pscurl -s https://tasks.example.com/api/healthdocker compose ps should show both containers as healthy. The health endpoint returns {"status":"ok",…}; see Health endpoint for its fields.
Pin a version
Section titled “Pin a version”The Compose file runs the latest image by default. To control upgrades, pin a version in .env:
DAY_PLANNER_VERSION=1.0.0Upgrading explains how to move to a newer version.
See also
Section titled “See also”- Configuration: every setting
- Backups and restore: set this up before you rely on it
- Reverse proxy and client IPs: HTTPS and correct rate limiting
- Configuration needed: if the app shows a list of settings to fix