Skip to main content

Docker Installation

Install Bellamy Book with Docker Compose when you have the full application source code. This guide is for running the full stack (infrastructure + backend + frontend + admin) from the project.

If you only have the self-host kit (a folder with docker-compose.yml and pre-built images, no source code), use Self-Host with Pre-Built Images instead. That guide is standalone and does not reference this page.

Prerequisites

  • Docker 20.10+
  • Docker Compose 2.0+

Resource requirements (production)

DeploymentCPURAMStorage
Production — full stack8+ cores16GB+200GB+ SSD

Production: Full stack (when you have the source)

Use this to run the entire application (infrastructure + backend + frontend + admin + workers) behind Traefik. Access is by hostname (e.g. bellamybook.com), not localhost ports.

Step 1: Clone and enter the project’s Docker folder

Clone the repository and go to the folder that contains the production docker-compose.yml (in the full project this is often named dockerProd or similar).

Step 2: Configure environment

Copy .env.example to .env and set all required values: database passwords, Traefik hosts (e.g. TRAEFIK_FRONTEND_HOST, TRAEFIK_ADMIN_HOST), and any other variables listed in that folder’s README.

Step 3: Start full stack

docker compose up -d

This starts infrastructure, backend API (api), frontend, admin panel, and workers. Traefik routes traffic by host.

Step 4: Run migrations

docker compose exec api dotnet ef database update --project DatabaseApplication

Step 5: Create admin user (optional)

docker compose exec api dotnet run --project DatabaseApplication -- seed-admin

Default admin account (after seeding): Email [email protected], Password Admin123@. Change this password immediately after first login (e.g. in Admin Panel → Profile or account settings).

Step 6: Verify and access

docker compose ps

Access the app at the URLs configured for Traefik (e.g. https://bellamybook.com for frontend, https://admin.bellamybook.com for admin). See that folder’s README and your .env for hostnames and TLS.


Local only: infrastructure in Docker, app from source

For local development, when you only need infrastructure in Docker and run the app from the project source:

Go to the folder in the project that contains the local Docker Compose file. Create the MongoDB keyfile (openssl rand -base64 756 > mongo-keyfile && chmod 400 mongo-keyfile), then docker compose up -d. Run backend, frontend, and admin from the project (see main repository README and Manual Installation). Defaults are in docker-compose.yml.


Deploy the Documentation Site

To run the documentation site in Docker, from the project root go to the docs-app folder, build the image, and run it. Then open http://localhost:8080 for the docs.

Customization

Change ports or hosts

Edit .env and Traefik labels in docker-compose.yml (e.g. TRAEFIK_FRONTEND_HOST, TRAEFIK_ADMIN_HOST). For SSL/HTTPS, Traefik is already configured; see the folder’s README and the traefik/ directory.

Maintenance

docker compose logs -f api
docker compose logs -f frontend
docker compose down
git pull && docker compose build && docker compose up -d

Troubleshooting

  • Port already in use: Change ports or stop conflicting services.
  • Database connection issues: Check .env and connection strings in docker-compose.yml.
  • Out of memory: Ensure 16GB+ RAM for the full stack; see the project’s resource docs if available.

See the main Troubleshooting guide for more.

Next Steps