mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-16 05:19:40 +02:00
Replace window injection and build-time env vars with runtime config loaded from /config.json (generated by Docker entrypoint). This fixes the staging deployment issue where apps were requesting localhost URLs instead of production URLs. Changes: - Add runtime.ts config loader with Zod validation (fail-hard in prod) - Disable SSR via +layout.ts (apps are client-only SPAs) - Update API clients and auth stores to use async config getters - Add docker-entrypoint.sh scripts to generate config.json at startup - Update Dockerfiles with ENTRYPOINT for config generation - Simplify docker-compose.staging.yml env vars (12-factor pattern) - Add static/config.json as dev fallback (localhost defaults) - Fix onMount return type (Svelte 5 compatibility) - Add zod dependency to Picture app - Add backward compat exports for Contacts app Apps updated: - Clock (port 3017) - Chat (port 3002) - Picture (port 3006) - Contacts (port 3015) - Calendar (port 3016) - Manacore (multi-app platform) Benefits: - Build once, deploy anywhere (same Docker image for all envs) - Configuration in environment, not code (12-factor compliance) - Fail-hard on missing/invalid config in production - No accidental SSR localhost fallbacks - Schema validation ensures all required URLs are present |
||
|---|---|---|
| .. | ||
| apps | ||
| packages/shared | ||
| CLAUDE.md | ||
| package.json | ||
| README.md | ||
Kalender
Smart Calendar Management - Organisiere deine Zeit intelligent
Eine vollständige Kalender-Anwendung mit persönlichen und geteilten Kalendern, wiederkehrenden Terminen, CalDAV/iCal-Synchronisation und Erinnerungen.
Features
- Mehrere Kalender - Verwalte verschiedene Kalender für Arbeit, Privates, Familie
- Kalenderansichten - Tag, Woche, Monat, Agenda
- Wiederkehrende Termine - Flexible Wiederholungsregeln (RFC 5545)
- Kalender teilen - Mit Familie, Freunden oder Kollegen
- CalDAV/iCal Sync - Google Calendar, Apple, Outlook
- Smarte Erinnerungen - Push & E-Mail Benachrichtigungen
- Multi-Sprache - Deutsch, English, Français, Español, Italiano
Quick Start
# 1. PostgreSQL starten (falls nicht läuft)
docker compose -f docker-compose.dev.yml up -d postgres
# 2. Datenbank erstellen
PGPASSWORD=devpassword psql -h localhost -U manacore -d postgres -c "CREATE DATABASE calendar;"
# 3. Schema pushen
pnpm calendar:db:push
# 4. Backend + Web starten
pnpm dev:calendar:app
Apps
| App | Port | Beschreibung |
|---|---|---|
| Backend | 3014 | NestJS REST API |
| Web | 5179 | SvelteKit Web-App |
| Landing | 4322 | Astro Marketing-Seite |
| Mobile | - | Expo App (TODO) |
Tech Stack
- Backend: NestJS, Drizzle ORM, PostgreSQL
- Web: SvelteKit, Svelte 5, Tailwind CSS
- Landing: Astro, Tailwind CSS
- Auth: Mana Core Auth (JWT)
Dokumentation
Siehe CLAUDE.md für die vollständige technische Dokumentation.
Entwicklung
# Einzelne Apps starten
pnpm dev:calendar:backend # Backend
pnpm dev:calendar:web # Web-App
pnpm dev:calendar:landing # Landing Page
# Datenbank
pnpm calendar:db:push # Schema pushen
pnpm calendar:db:studio # Drizzle Studio öffnen
API Endpunkte
| Modul | Endpunkt | Beschreibung |
|---|---|---|
| Health | GET /api/v1/health |
Health Check |
| Calendars | GET/POST /api/v1/calendars |
Kalender CRUD |
| Events | GET/POST /api/v1/events |
Termine CRUD |
| Reminders | POST /api/v1/events/:id/reminders |
Erinnerungen |
| Shares | POST /api/v1/calendars/:id/shares |
Freigaben |
| Sync | POST /api/v1/sync/caldav/discover |
CalDAV |
Lizenz
Proprietär - Manacore