Initial commit: DOCX Template Server mit API und Tabellen-Support
- ✅ Node.js/Express Server mit DOCX Template-Verarbeitung - ✅ Automatische Tag-Erkennung und Demo-Daten-Generierung - ✅ Tabellen-Unterstützung mit Schleifen-Tags - ✅ REST-API /api/process-template für externe Integration - ✅ Web-Oberfläche mit vollständiger Dokumentation - ✅ SSL-Unterstützung (HTTPS Port 443 öffentlich) - ✅ Intelligente Spaltenerkennung für Tabellen - ✅ Detaillierte Statusmeldungen für alle Operationen - ✅ Flexible Custom-Daten + Auto-Generierung - ✅ Template- und Dokument-Management APIs
This commit is contained in:
129
SSL-SETUP.md
Normal file
129
SSL-SETUP.md
Normal file
@@ -0,0 +1,129 @@
|
||||
# 🔒 SSL-Konfiguration für DOCX Template Server
|
||||
|
||||
## ✅ Server ist für Ihre Zertifikate konfiguriert!
|
||||
|
||||
Der Server erwartet Ihre SSL-Zertifikate im Projektverzeichnis:
|
||||
- **Zertifikat:** `/home/OfficeServerJS/203_cert.pem`
|
||||
- **Privater Schlüssel:** `/home/OfficeServerJS/203_key.pem`
|
||||
|
||||
## 🚀 SSL aktivieren
|
||||
|
||||
### Schritt 1: Zertifikate bereitstellen
|
||||
Kopieren Sie Ihre Zertifikatsdateien ins Projektverzeichnis:
|
||||
|
||||
```bash
|
||||
# Wechseln ins Projektverzeichnis
|
||||
cd /home/OfficeServerJS
|
||||
|
||||
# Prüfen ob Zertifikate vorhanden sind
|
||||
ls -la 203_cert.pem 203_key.pem
|
||||
|
||||
# Falls sie woanders liegen, kopieren Sie sie:
|
||||
# cp /pfad/zu/ihrem/203_cert.pem /home/OfficeServerJS/
|
||||
# cp /pfad/zu/ihrem/203_key.pem /home/OfficeServerJS/
|
||||
|
||||
# Berechtigungen setzen (empfohlen)
|
||||
chmod 600 203_key.pem
|
||||
chmod 644 203_cert.pem
|
||||
```
|
||||
|
||||
### Schritt 2: Server mit SSL starten
|
||||
```bash
|
||||
# Option 1: Mit SSL-Check-Script
|
||||
cd /home/OfficeServerJS
|
||||
./start-ssl.sh
|
||||
|
||||
# Option 2: Normal starten (erkennt SSL automatisch)
|
||||
./start.sh
|
||||
```
|
||||
|
||||
## 🌐 Endpunkte nach SSL-Aktivierung
|
||||
|
||||
### HTTP (immer verfügbar):
|
||||
- **Web-Interface:** http://localhost:80
|
||||
- **Templates:** http://localhost:80/webdav/templates/
|
||||
- **Dokumente:** http://localhost:80/webdav/documents/
|
||||
|
||||
### HTTPS (nach SSL-Aktivierung):
|
||||
- **Web-Interface:** https://localhost:443
|
||||
- **Templates:** https://localhost:443/webdav/templates/
|
||||
- **Dokumente:** https://localhost:443/webdav/documents/
|
||||
|
||||
## 🔧 Zertifikat-Validierung
|
||||
|
||||
Das `start-ssl.sh` Script prüft automatisch:
|
||||
- ✅ Existenz der Zertifikatsdateien
|
||||
- ✅ Gültigkeit des Zertifikats
|
||||
- ✅ Kompatibilität zwischen Zertifikat und Schlüssel
|
||||
- ✅ Gültigkeitsdauer
|
||||
|
||||
## 📋 Produktions-Checkliste
|
||||
|
||||
Für den Einsatz in der Produktion:
|
||||
|
||||
### Firewall-Konfiguration:
|
||||
```bash
|
||||
# Ports öffnen
|
||||
ufw allow 80/tcp
|
||||
ufw allow 443/tcp
|
||||
```
|
||||
|
||||
### DNS-Konfiguration:
|
||||
- A-Record Ihrer Domain auf Server-IP setzen
|
||||
- Falls Wildcard-Zertifikat: Subdomains konfigurieren
|
||||
|
||||
### Automatischer Start:
|
||||
```bash
|
||||
# Systemd Service erstellen
|
||||
sudo cp /home/OfficeServerJS/systemd-service-template.service /etc/systemd/system/docx-server.service
|
||||
sudo systemctl enable docx-server
|
||||
sudo systemctl start docx-server
|
||||
```
|
||||
|
||||
### Zertifikat-Erneuerung:
|
||||
- Automatische Erneuerung einrichten (falls Let's Encrypt)
|
||||
- Monitoring für Zertifikat-Ablauf
|
||||
|
||||
## 🚨 Troubleshooting
|
||||
|
||||
### Zertifikat wird nicht erkannt:
|
||||
```bash
|
||||
# Pfade prüfen
|
||||
cd /home/OfficeServerJS
|
||||
ls -la 203_*.pem
|
||||
|
||||
# Berechtigungen prüfen
|
||||
chmod 600 203_key.pem
|
||||
chmod 644 203_cert.pem
|
||||
|
||||
# Zertifikat-Format prüfen
|
||||
openssl x509 -in 203_cert.pem -text -noout
|
||||
```
|
||||
|
||||
### Port 443 bereits belegt:
|
||||
```bash
|
||||
# Prüfen was Port 443 belegt
|
||||
sudo netstat -tlnp | grep :443
|
||||
sudo lsof -i :443
|
||||
|
||||
# Falls Apache/Nginx läuft, stoppen oder Port ändern
|
||||
sudo systemctl stop apache2
|
||||
sudo systemctl stop nginx
|
||||
```
|
||||
|
||||
### SSL-Handshake-Fehler:
|
||||
- Zertifikat-Kette vollständig? (Intermediate-Zertifikate)
|
||||
- Zertifikat für richtige Domain ausgestellt?
|
||||
- Privater Schlüssel passt zum Zertifikat?
|
||||
|
||||
## ✅ Status-Check
|
||||
|
||||
Nach dem Start sollten Sie sehen:
|
||||
```
|
||||
✅ Zertifikat gefunden: /home/OfficeServerJS/203_cert.pem
|
||||
✅ Privater Schlüssel gefunden: /home/OfficeServerJS/203_key.pem
|
||||
✅ Zertifikat und privater Schlüssel passen zusammen
|
||||
🔒 HTTPS Server läuft auf Port 443
|
||||
```
|
||||
|
||||
**Ihre SSL-Konfiguration ist bereit! Platzieren Sie die Zertifikate im `/home/OfficeServerJS/` Verzeichnis.**
|
||||
Reference in New Issue
Block a user