move documentation/ to docs/

This commit is contained in:
2026-03-08 20:00:08 +00:00
parent 604b52bcc7
commit 006a28ea0f
58 changed files with 41 additions and 0 deletions

41
docs/architecture.md Normal file
View File

@@ -0,0 +1,41 @@
# Voyage Architecture
> **Status**: Stub — to be expanded as architecture evolves.
## Overview
Voyage is a self-hosted travel companion built with SvelteKit (frontend) and Django REST Framework (backend), deployed via Docker.
## Key Architectural Patterns
### API Proxy
The frontend never calls Django directly. All API calls go through `src/routes/api/[...path]/+server.ts`, which proxies to the Django server, injecting CSRF tokens and managing session cookies.
### Services (Docker Compose)
- `web` → SvelteKit frontend (`:8015`)
- `server` → Django via Gunicorn + Nginx (`:8016`)
- `db` → PostgreSQL + PostGIS (`:5432`)
- `cache` → Memcached (internal)
### Authentication
Session-based via `django-allauth`. CSRF tokens from `/auth/csrf/`, passed as `X-CSRFToken` header.
## Backend Apps
- `adventures` — core domain (locations, collections, itineraries, notes, transportation, MCP)
- `users` — user management
- `worldtravel` — countries, regions, cities, visited tracking
- `integrations` — external service integrations
- `achievements` — gamification
- `chat` — LLM chat/agent
## Frontend Structure
- `src/routes/` — SvelteKit file-based routing
- `src/lib/types.ts` — TypeScript interfaces
- `src/lib/components/` — Svelte components by domain
- `src/locales/` — i18n JSON files
## TODO
- [ ] Data flow diagrams
- [ ] Database schema overview
- [ ] Deployment architecture
- [ ] MCP endpoint architecture

View File

Before

Width:  |  Height:  |  Size: 82 KiB

After

Width:  |  Height:  |  Size: 82 KiB

View File

Before

Width:  |  Height:  |  Size: 82 KiB

After

Width:  |  Height:  |  Size: 82 KiB

View File

Before

Width:  |  Height:  |  Size: 337 KiB

After

Width:  |  Height:  |  Size: 337 KiB

View File

Before

Width:  |  Height:  |  Size: 224 KiB

After

Width:  |  Height:  |  Size: 224 KiB

View File

Before

Width:  |  Height:  |  Size: 335 KiB

After

Width:  |  Height:  |  Size: 335 KiB

View File

Before

Width:  |  Height:  |  Size: 87 KiB

After

Width:  |  Height:  |  Size: 87 KiB

View File

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 16 KiB

View File

Before

Width:  |  Height:  |  Size: 87 KiB

After

Width:  |  Height:  |  Size: 87 KiB