Vault initial

This commit is contained in:
Hermes (Server)
2026-08-17 10:56:15 +02:00
parent 26cc1e86b0
commit 3274c11938
12 changed files with 625 additions and 192 deletions
+58
View File
@@ -0,0 +1,58 @@
# Melo Cloud Sync Phasen-Plan
> Stand: 26.07.2026
> Server: Aingrad (Netcup RS 1000)
> Technik: Python/Flask + SQLite + Symlinks
---
## 🔴 **Phase 1: Registry-Server**
```
/var/lib/melo-cloud/
├── registry/ ← Alle Songs (nur 1x physisch)
│ └── abc123.mp3
├── users/
│ ├── baka/ ← Symlinks auf registry/
│ └── melo/ ← Symlinks auf registry/
└── covers/ ← Original-Cover von YouTube
```
- [ ] Flask API (Port 8993)
- [ ] SQLite DB mit `registry` + `user_songs` Tabellen
- [ ] Auth per Navidrome-Credentials
- [ ] Upload-API: SHA256-Check → fpcalc-Fingerprint → speichern in Registry → Hardlink
- [ ] Deduplizierung: SHA256 + Fingerprint + Titel-Similarität (>90%)
- [ ] Custom-Titel/Cover pro User
- [ ] Systemd-Service `melo-cloud.service`
## 🟡 **Phase 2: Sync-API**
- [ ] `POST /api/cloud/upload` MP3 hochladen + Registry-Check
- [ ] `GET /api/cloud/download` Song vom Server runterladen
- [ ] `GET /api/cloud/list` Alle eigenen Songs + Status
- [ ] `DELETE /api/cloud/delete` Link in User-Cloud löschen
- [ ] `GET /api/cloud/status` Übersicht (Count, letzter Sync)
## 🟢 **Phase 3: CloudScreen (Flutter)**
- [ ] Neuer Tab "Cloud" mit Bottom-Nav
- [ ] Upload: Lokale MP3s → Server mit Fortschritt
- [ ] Download: Server-Songs → Lokal (Batch)
- [ ] Sync-Logik: `checkLocalVsServer()` → Diff anzeigen
- [ ] Sync-Intervall: Manuell / 3h / 6h / 12h
## 🔵 **Phase 4: Playlist-Teilen**
- [ ] Share-Button → 6-stelliger Code generieren
- [ ] Code eingeben → Playlist importieren
- [ ] "Nur passende Songs" / "Alle inkl. fehlende" Auswahl
- [ ] Matching: Per `registry.orig_title` → Levenshtein-Abgleich
## 🟣 **Phase 5: Geräteübergreifender Sync**
- [ ] Push-Benachrichtigung bei neuen Songs
- [ ] Auto-Sync nach Intervall
- [ ] Lösch-Sync über Geräte
- [ ] Konflikte: Server = Source of Truth
- [ ] Sync-Protokoll (letzte 50 Aktionen)