admin 2e875ed1ad fix: backup — mariadb-dump, --skip-ssl, SSH-Key per Volume in Compose
- mariadb-dump statt mysqldump (kein Deprecation-Warning in Alpine)
  via BACKUP_DUMP_CMD konfigurierbar (Fallback für lokale MySQL-Umgebung)
- --skip-ssl unterdrückt MariaDB-SSL-Warnung bei MYSQL_PWD-Nutzung
- docker-compose.prod.yml: BACKUP_SSH_URL + Key-Volume (BACKUP_SSH_KEY_FILE)
  damit SSH-Alias-Auflösung und Key-Zugriff im Container funktionieren

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-05 13:54:43 +02:00
2026-05-31 15:34:34 +00:00
2026-05-31 17:42:07 +00:00
2026-05-31 15:34:34 +00:00
2026-05-31 17:42:07 +00:00

This is a Next.js project bootstrapped with create-next-app.

Getting Started

First, run the development server:

npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev

Open http://localhost:3000 with your browser to see the result.

You can start editing the page by modifying app/page.tsx. The page auto-updates as you edit the file.

This project uses next/font to automatically optimize and load Geist, a new font family for Vercel.

Learn More

To learn more about Next.js, take a look at the following resources:

You can check out the Next.js GitHub repository - your feedback and contributions are welcome!

Deploy on Vercel

The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.

Check out our Next.js deployment documentation for more details.

Neue Features (Statistik Grafik Proxy)

  • Proxy für das interne Statistik-Portal:

    • Neuer Server-seitiger Proxy unter /api/statistik/grafik (und Catch-all /api/statistik/grafik/*).
    • Holt die Statistik-Seite serverseitig mit Basic-Auth und gibt sie an den Browser weiter, damit Zugangsdaten nicht im Client landen.
    • Leitet auch CSS/JS/Images und AJAX-POSTs durch den Proxy (weitergeleitete Methoden und Bodies werden erhalten).
    • Die HTML-Antwort wird bereinigt und relative URLs so umgeschrieben, dass Assets über die Proxy-URL geladen werden (<base href="/api/statistik/grafik/">).
  • Environment-Variablen (server-side only):

    • STATISTIK_GRAFIK_URL — Basis-URL des internen Statistik-Portals (z. B. https://sternwarte-welzheim.de/intern/statistik).
    • STATISTIK_GRAFIK_USER — Benutzername für Basic-Auth.
    • STATISTIK_GRAFIK_PASS — Passwort für Basic-Auth.
  • UI-Änderung:

    • Der Grafik-Button in der Statistik-Ansicht öffnet jetzt die Statistik-Seite in einem neuen Fenster (window.open('/api/statistik/grafik', '_blank')). Die vorherige iframe-Integration wurde entfernt, da Browser (insb. Firefox/Safari) bei Einbettung Probleme mit X-Frame-Options/CSP gemacht haben.
  • Middleware / Sicherheit:

    • Die Proxy-Route wird in der App-Auth-Middleware erlaubt, so dass der Proxy die Statistik-Seite auch ohne Benutzer-Session laden kann (Zugangskontrolle erfolgt über die serverseitigen Basic-Auth-Variablen).
  • Datenbank-Backup:

    • Das neue Skript backup_db.sh erzeugt ein tägliches MySQL-Dump-Backup im Verzeichnis DB_BACKUP/.
    • Standardmäßig werden Backups älter als 7 Tage automatisch gelöscht.
    • Beispiel-Cron-Eintrag für täglich 02:00 Uhr:
0 2 * * * cd /pfad/zum/repo && DB_ROOT_PASS=deinrootpass DB_NAME=sternwarte ./backup_db.sh --days 7

Hinweis: Speichere sensible Zugangsdaten nicht in Repositories. Setze die drei STATISTIK_... Variablen in deiner Deployment-Umgebung (z. B. Docker secrets, CI/CD environment variables oder auf dem Server). Die Proxy-Implementierung entfernt framing-blockierende Header und schiebt relative Asset-Pfade durch den Proxy, um Kompatibilitätsprobleme mit Browsern zu vermeiden.

Test, ob das nun Deployed, wenn auf main gepushed wird.

S
Description
Logbuch für die Sternwqarte-Welzherim
Readme 1.3 MiB
Languages
TypeScript 81.3%
HTML 9.6%
Shell 7.8%
Dockerfile 0.6%
CSS 0.4%
Other 0.3%