diff --git a/Architecture.md b/Architecture.md index 40a4998..a971941 100644 --- a/Architecture.md +++ b/Architecture.md @@ -35,21 +35,25 @@ crates/ ## Traffic Flow +In production, Traefik is the entry point (shared external service). API and frontend run on separate subdomains — no internal proxy needed. + ``` User's Browser │ ▼ - Nginx (Reverse Proxy) - ├── /api/* ──────────────► thoughts (API server :8000) - │ /.well-known/* │ - │ /users/* (AP Accept) └──► PostgreSQL - │ │ - └── /* ──────► Next.js NATS JetStream - Frontend │ - thoughts-worker - (AP delivery, notifications) + Traefik (external, shared) + ├── api.domain.com ──────► thoughts (API server :8000) + │ │ + └── domain.com ──────────► Next.js Frontend (:3000) + │ + PostgreSQL NATS JetStream + │ + thoughts-worker + (AP delivery, notifications) ``` +In development, services are exposed directly on localhost ports — no proxy needed. + ## Domain Layer `crates/domain` defines only pure types and port traits — no framework or DB dependencies: