mirror of
https://github.com/skoelle/calender_sync.git
synced 2026-09-17 18:20:24 +00:00
demo showcase README.md
This commit is contained in:
@@ -9,7 +9,7 @@ Python-basierter Google Calendar → MariaDB Synchronizer. Läuft als Docker Con
|
||||
## Technologie-Stack
|
||||
|
||||
- **Sprache**: Python 3.12
|
||||
- **Datenbank**: MariaDB (mysql-connector-python)
|
||||
- **Datenbank**: MariaDB (mysql-connector-python) oder SQLite (stdlib) via `DB_BACKEND` Env-Var
|
||||
- **API**: FastAPI + Uvicorn + Jinja2
|
||||
- **Docker**: Multi-Stage Build nicht verwendet, simples Slim-Image
|
||||
- **Dependencies**: requests, icalendar, recurring-ical-events, mysql-connector-python, fastapi, uvicorn, jinja2
|
||||
@@ -21,9 +21,12 @@ Python-basierter Google Calendar → MariaDB Synchronizer. Läuft als Docker Con
|
||||
├── sync.py # Hauptskript (alles in einer Datei)
|
||||
├── api/
|
||||
│ ├── main.py # FastAPI App (REST API + HTML UI)
|
||||
│ ├── database.py # DB-Verbindung für die API
|
||||
│ ├── database.py # DB-Verbindung (MySQL + SQLite)
|
||||
│ └── templates/
|
||||
│ └── index.html # Jinja2 Template für Web-UI
|
||||
├── demo/
|
||||
│ └── seed.py # SQLite Demo-Datenbank erstellen
|
||||
├── demo.sh # Lokaler Demo-Start (ohne Docker)
|
||||
├── requirements.txt # Python Dependencies
|
||||
├── Dockerfile # Docker Image Definition
|
||||
├── docker-compose.yml # Docker Compose Konfiguration
|
||||
@@ -71,7 +74,7 @@ Sendet täglich um konfigurierte Uhrzeit eine HTML-Email mit anstehenden Termine
|
||||
|
||||
## Entwicklung
|
||||
|
||||
### Lokaler Test
|
||||
### Lokaler Test (Docker)
|
||||
```bash
|
||||
# Dependencies installieren
|
||||
pip install -r requirements.txt
|
||||
@@ -83,6 +86,20 @@ cp .env.example .env
|
||||
python sync.py
|
||||
```
|
||||
|
||||
### Lokaler Test (Demo, ohne MariaDB)
|
||||
```bash
|
||||
# Startet venv, erstellt SQLite Demo-DB mit 4 Events, startet API
|
||||
./demo.sh
|
||||
```
|
||||
|
||||
Oder manuell:
|
||||
```bash
|
||||
python3 -m venv .venv && source .venv/bin/activate
|
||||
pip install -r requirements.txt
|
||||
python demo/seed.py
|
||||
DB_BACKEND=sqlite DB_PATH=demo/demo.db python -m uvicorn api.main:app --port 8000
|
||||
```
|
||||
|
||||
### Linting & Type Checking
|
||||
Keine Linting/Type-Checking Tools konfiguriert. Bei Bedarf hinzufügen:
|
||||
- `ruff` für Linting
|
||||
|
||||
Reference in New Issue
Block a user