1.7 KiB
1.7 KiB
BizMatch Deployment Guide
Übersicht
| Umgebung | Befehl | Port | SSR |
|---|---|---|---|
| Development | npm start |
4200 | ❌ Aus |
| Production | npm run build:ssr → npm run serve:ssr |
4200 | ✅ An |
Development (Lokale Entwicklung)
cd ~/bizmatch-project/bizmatch
npm start
- Läuft auf http://localhost:4200
- Hot-Reload aktiv
- Kein SSR (schneller für Entwicklung)
Production Deployment
1. Build erstellen
npm run build:ssr
Erstellt optimierte Bundles in dist/bizmatch/
2. Server starten
Direkt (zum Testen):
npm run serve:ssr
Mit PM2 (empfohlen für Production):
# Einmal PM2 installieren
npm install -g pm2
# Server starten
pm2 start dist/bizmatch/server/server.mjs --name "bizmatch"
# Nach Code-Änderungen
npm run build:ssr && pm2 restart bizmatch
# Logs anzeigen
pm2 logs bizmatch
# Status prüfen
pm2 status
3. Nginx Reverse Proxy (optional)
server {
listen 80;
server_name deinedomain.com;
location / {
proxy_pass http://localhost:4200;
proxy_http_version 1.1;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
}
}
SEO Features (aktiv mit SSR)
- ✅ Server-Side Rendering für alle Seiten
- ✅ Meta-Tags und Titel werden serverseitig generiert
- ✅ Sitemaps unter
/sitemap.xml - ✅ robots.txt konfiguriert
- ✅ Strukturierte Daten (Schema.org)
Wichtige Dateien
| Datei | Zweck |
|---|---|
server.ts |
Express SSR Server |
src/main.server.ts |
Angular Server Entry Point |
src/ssr-dom-polyfill.ts |
DOM Polyfills für SSR |
dist/bizmatch/server/ |
Kompilierte Server-Bundles |