chore: Screenshot-Instanz mit eingerichteten Meldewegen
Die Wegwerf-Instanz bekommt je Lauf ein frisch erzeugtes VAPID-Paar und einen Mailhost, den es nie geben wird. Damit zeigen die Bilder den eingerichteten Normalfall statt zweier Warnhinweise — und im Verzeichnis bleibt kein privater Schluessel liegen. Kein Push-Geraet mehr in den Demo-Daten: Seine Schluessel liegen verschluesselt, und der Versand entfernt jedes Geraet, dessen Schluessel er nicht lesen kann. Der erfundene Eintrag waere beim ersten Lauf wieder verschwunden. Dass der Browser im Bild "blockiert" meldet, laesst sich nicht abstellen: Chromium im Kopflosbetrieb antwortet auf Notification.permission immer so. Das Handbuch sagt es jetzt dazu. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
7bef4351ec
commit
35ecb2fa78
@@ -14,6 +14,7 @@
|
||||
*/
|
||||
import { spawnSync } from 'node:child_process'
|
||||
import { fileURLToPath } from 'node:url'
|
||||
import webpush from 'web-push'
|
||||
|
||||
const WURZEL = fileURLToPath(new URL('..', import.meta.url))
|
||||
const PROJEKT = 'planer-screenshots'
|
||||
@@ -22,10 +23,16 @@ const COMPOSE_DATEI = 'docker-compose.screenshots.yml'
|
||||
const APP_PORT = process.env.SCREENSHOT_APP_PORT ?? '3200'
|
||||
const DB_PORT = process.env.SCREENSHOT_DB_PORT ?? '5455'
|
||||
|
||||
// Frisches Paar je Lauf: Die Bilder sollen die eingerichtete Anwendung
|
||||
// zeigen, ohne dass irgendwo ein privater Schluessel liegen bleibt.
|
||||
const VAPID = webpush.generateVAPIDKeys()
|
||||
|
||||
const UMGEBUNG = {
|
||||
...process.env,
|
||||
SCREENSHOT_APP_PORT: APP_PORT,
|
||||
SCREENSHOT_DB_PORT: DB_PORT,
|
||||
SCREENSHOT_VAPID_OEFFENTLICH: VAPID.publicKey,
|
||||
SCREENSHOT_VAPID_PRIVAT: VAPID.privateKey,
|
||||
}
|
||||
|
||||
function meldung(text: string): void {
|
||||
|
||||
Reference in New Issue
Block a user