- Source-Copy von /root/entwicklung/pfandsystem - docker-compose.yml umgeschrieben: pfandsystem-demo-* Container, Ports 3308/8083/3003 (alle localhost) - Traefik-Label fuer pfandsystem.dockly.de - Erweitertes Multi-Tenant-Schema (tenants, tenant_id auf allen Tabellen) - Neue Tabellen: kunden_bilder, geraete - Neue Spalten: kunden.anlieferungshinweis, kunden.lieferzeit_bis - Rollen: superadmin, admin, user, fahrer - .env.example + README Code-Refactor (Tailwind, Multi-Tenant-Middleware, Erweiterungen) folgt.
2.0 KiB
2.0 KiB
Sofortige Fixes für die 3 Hauptprobleme
Problem 1: Login geht nicht ✅ GELÖST
Ursache: Backend crashed beim Login-Request Lösung: Backend läuft jetzt lokal (außerhalb Docker) bis Docker-Problem behoben
# Backend lokal starten (temporär)
cd /root/backend
npm start &
# Test:
curl http://localhost:3001/health
# Sollte: {"status":"OK",...}
Problem 2: SSL geht nicht ⚠️ IN ARBEIT
Ursache: nginx im Docker hat keine SSL-Zertifikate gemountet Lösung: Verwende externen nginx (bereits läuft) oder mounte Zertifikate
Temporäre Lösung - HTTP verwenden:
# Frontend .env anpassen
echo "VITE_API_URL=http://pfandsystem.backdigital.de/api" > /root/.env
# Neu bauen
npm run build
node fix-manifest-link.cjs
Permanente Lösung - Externer nginx: Nginx läuft bereits auf dem Host und hat SSL. Wir müssen nur Proxy konfigurieren.
Problem 3: Git Repository ✅ GELÖST
# Git konfiguriert
git config user.email "vonperfall@r83.io"
git config user.name "christian"
git remote add origin ssh://git@49.13.154.75:2244/christian/pfandsystem.git
# Branches erstellt
git branch -M main
git branch development
git branch testing
# Pushen:
git push -u origin main
git push origin development
git push origin testing
Schnellstart-Befehle
# 1. MySQL & phpMyAdmin starten
docker compose up -d mysql phpmyadmin
# 2. Backend lokal starten
cd /root/backend && npm start &
# 3. Frontend neu bauen
cd /root
npm run build
node fix-manifest-link.cjs
# 4. Testen
curl http://localhost:3001/health
curl -X POST http://localhost:3001/api/auth/login \
-H "Content-Type: application/json" \
-d '{"email":"admin@pfandsystem.de","password":"admin123"}'
# 5. Git pushen
git add -A
git commit -m "Fix: Backend läuft lokal, Git konfiguriert"
git push -u origin main
Nächste Schritte
- Backend-Docker-Problem beheben (später)
- SSL konfigurieren (externer nginx)
- Frontend deployen
- Testen