Skip to main content
Version: Next

Docker Compose

Use these examples to run OpenReader with Kokoro-FastAPI and persistent storage. Choose the slim stack for the simplest deployment, or the full stack when you want PostgreSQL, SeaweedFS, NATS, and the compute worker as separate containers. Local build variants are also available for both slim and full stacks to build the application from your current checkout.

Prerequisites

  • A recent Docker version with Docker Compose
  • A clone of the OpenReader repository
git clone https://github.com/richardr1126/openreader.git
cd openreader

Choose a stack

The default slim example runs:

  • OpenReader with embedded SeaweedFS, NATS, compute worker, and SQLite
  • Kokoro-FastAPI as a companion container
docker compose -f docker/examples/compose.yml up
# Repository convenience command: pnpm compose

Compose file: docker/examples/compose.yml

Included services

ServiceSlimFullLocal SlimLocal Full
OpenReaderPublished imagePublished imageLocal buildLocal build
Kokoro-FastAPIContainerContainerContainerContainer
DatabaseEmbedded SQLitePostgreSQL containerEmbedded SQLitePostgreSQL container
SeaweedFSEmbeddedContainerEmbeddedContainer
NATSEmbeddedContainerEmbeddedContainer
Compute workerEmbeddedPublished imageEmbeddedLocal build

On first boot, RUNTIME_SEED_JSON creates an enabled Kokoro shared provider and selects it as the default TTS provider.

Endpoints

  • OpenReader: http://localhost:3003
  • SeaweedFS S3: http://localhost:8333
  • Kokoro-FastAPI: http://localhost:8880

In the full examples, PostgreSQL, the compute worker, and NATS remain internal to the Compose network.

LAN access

Set BASE_URL and S3_ENDPOINT to the Docker host's LAN IP so browser-facing app and presigned S3 URLs are reachable from other devices:

BASE_URL=http://192.168.0.XXX:3003 \
S3_ENDPOINT=http://192.168.0.XXX:8333 \
docker compose -f docker/examples/compose.yml up
# Repository convenience command: pnpm compose

Replace 192.168.0.XXX with your Docker host's LAN IP and allow inbound TCP ports 3003 and 8333 through its firewall.

Internal full-stack endpoint

The full and local-full compute workers continue using http://seaweedfs:8333 internally. S3_ENDPOINT configures the app endpoint and browser-facing presigned URLs.

Configuration

The examples use local-only default credentials. Override existing ${VARIABLE} values through your shell environment before using them beyond local development.

Protect public deployments

Replace the default AUTH_SECRET, PostgreSQL credentials, S3 credentials, and compute-worker token before exposing a stack outside your trusted local network.

For the complete configuration reference, see Environment Variables. See Database for PostgreSQL and SQLite behavior.