Docker Development

July 27, 2026 ยท View on GitHub

Run local infrastructure (PostgreSQL + the database migrator) in Docker, then run the .NET services and Angular apps on the host.

Prerequisites

  • Docker Desktop running
  • .NET 10 SDK
  • Bun (for the Angular apps)

Quick Start

git clone https://github.com/suxrobgm/logistics-app.git
cd logistics-app

# Start Postgres and run the migrator once (creates DBs + seeds dev data)
docker compose -f deploy/docker-compose.dev.yml up -d

Then run the backend and a frontend on the host:

dotnet run --project src/Presentation/Logistics.IdentityServer   # https://localhost:7001
dotnet run --project src/Presentation/Logistics.API              # https://localhost:7000

cd src/Client/Logistics.Angular
bun install
bun start:tms        # also: start:admin, start:customer, start:website

What the dev compose runs

From deploy/docker-compose.dev.yml:

ServiceURL / PortNotes
postgreslocalhost:5433Postgres 18; data in the logistics-pg-data volume
migratorruns once, then exitsMigrates master + tenant DBs, seeds the us/eu/solo tenants

The migrator builds from src/Presentation/Logistics.DbMigrator/Dockerfile and creates the master_logisticsx, us_logisticsx, eu_logisticsx, and solo_logisticsx databases.

Three demo tenants are seeded: us (Heartland Logistics LLC) and eu (EuroFreight GmbH) are fleets with 10 employees and 100 loads each; solo (Rodriguez Trucking LLC) runs in owner-operator mode with one person, one truck and 12 loads. Tenant metadata comes from the migrator's own appsettings.json; the compose file only overrides the connection strings, via Tenants__N__ConnectionString - the index has to match the tenant's position in that array. Adding a fourth tenant there means adding Tenants__3__ConnectionString here.

Service URLs

ServiceURL
API (Swagger)https://localhost:7000/swagger
Identity Serverhttps://localhost:7001
Admin Portalhttp://localhost:7002
TMS Portalhttp://localhost:7003
Customer Portalhttp://localhost:7004
Websitehttp://localhost:7005

App configuration / secrets

The .NET services read connection strings and secrets from their own appsettings.Development.json / user-secrets. The dev compose only provides the database; point the API and Identity Server at Host=localhost;Port=5433 (matching the published Postgres port).

Re-running migrations

docker compose -f deploy/docker-compose.dev.yml up migrator

Stopping / cleaning up

docker compose -f deploy/docker-compose.dev.yml down        # stop
docker compose -f deploy/docker-compose.dev.yml down -v     # stop + drop the DB volume

Next Steps