Docker

Run yarr in a Docker container with a persistent volume.

The image is available on Docker Hub and GitHub Container Registry.

Pull the image from the registry:

docker pull nkanaev/yarr:latest

Run the container:

docker run -d --name yarr \
  -p 7070:7070 \
  -v yarr-data:/data \
  nkanaev/yarr:latest -db /data/yarr.db -addr 0.0.0.0:7070

The database is stored in the volume yarr-data.

Docker Compose with PostgreSQL

To run yarr with PostgreSQL, use a docker-compose.yml file:

services:
  yarr:
    image: nkanaev/yarr:latest
    command: ["-addr", "0.0.0.0:7070"]
    environment:
      YARR_DB: postgres://dbuser:dbpass@postgres:5432/dbname?sslmode=disable
      YARR_AUTH: username:password
    ports:
      - "7070:7070"
    depends_on:
      postgres:
        condition: service_healthy

  postgres:
    image: postgres:17-alpine
    environment:
      POSTGRES_USER: dbuser
      POSTGRES_PASSWORD: dbpass
      POSTGRES_DB: dbname
    volumes:
      - postgres-data:/var/lib/postgresql/data
    healthcheck:
      test: ["CMD-SHELL", "pg_isready -U user -d dbname"]
      interval: 5s
      timeout: 5s
      retries: 5

volumes:
  postgres-data:

Start the services:

docker compose up -d