Skip to content

Docker quickstart

Docker Compose is the supported way to run YearRoll on a machine you control. The app listens on port 3456. PostgreSQL 16 runs next to it.

You need Docker Desktop, or Docker Engine with Compose v2.

Terminal window
git clone https://github.com/joharper54/yearroll.git
cd yearroll
Terminal window
cp .env.example .env

.env.example includes sample values so a local trial starts without editing. Replace POSTGRES_PASSWORD, AUTH_SECRET, SETUP_SECRET, and SEED_PASSWORD before a school uses the instance. What each variable does is in Configuration.

Terminal window
docker compose up --build
Service Port Purpose
web 3456 YearRoll
db 5432 PostgreSQL 16

The web container applies migrations from migrations/ before it listens. If a migration file fails, or the journal checksum does not match, the container exits. Postgres data is stored in the sis_pg_data volume.

Open http://127.0.0.1:3456.

On an empty database, open http://127.0.0.1:3456/setup. Enter the SETUP_SECRET from .env to create the first school admin.

Skip /setup if you load the demo seed below. The seed already creates staff accounts.

Terminal window
docker compose --profile tools run --rm seed

The seed reads SEED_PASSWORD from .env. The value must be at least 12 characters. When it finishes, it prints the demo staff and parent email addresses. Sign in with those addresses and SEED_PASSWORD.

The seed replaces demo rows. Do not run it against a database that already holds a real school.

Terminal window
curl -fsS http://127.0.0.1:3456/api/v1/health

A healthy instance responds with HTTP 200 and a body like:

{ "ok": true, "migrations": "applied" }

If migrations are pending, mismatched, or the check itself fails, the route responds with HTTP 503. See Backups and migrations.

docker compose down stops the containers and keeps the Postgres volume. docker compose down -v deletes that volume and the data in it.

Next: Hosting options.