Startseite: Anfrageformular sendet serverseitig, Landingpage und netcup-Ziel

- Neues oeffentliches Formular-Endpoint POST /anfrage (app/inquiry.php):
  Pflichtfelder ausser Nachricht, Validierung, Honeypot, IP-Limit 5/Stunde,
  Versand per mail_send() mit Reply-To des Kunden - kein mailto mehr
- mail_send() akzeptiert zusaetzliche Kopfzeilen (CRLF bereinigt)
- app.inquiry_email in Konfiguration und Deploy-Template (DIC_INQUIRY_EMAIL)
- Statische Landingpage web/index.html mit Assets, Service-Worker-Cache dic-v18
- App-Routen auf /dashboard, netcup-Deploy-Doku und Fundstellen aktualisiert
This commit is contained in:
torsten 2026-11-29 16:31:28 +01:00
parent 273eabfdb7
commit fe388838db
27 changed files with 2598 additions and 57 deletions

View file

@ -85,18 +85,25 @@ def main():
parser.add_argument("--force", action="store_true", help="vorhandene VAPID-Schlüssel überschreiben")
parser.add_argument("--subject", default=DEFAULT_SUBJECT, help="VAPID_SUBJECT (Default: %(default)s)")
parser.add_argument("--file", default=CRED_FILE, help="Zieldatei für --write")
parser.add_argument(
"--key-prefix",
default="VAPID",
help="Präfix der Keys, z. B. VAPID_LIVE für das netcup-Ziel (Default: %(default)s)",
)
args = parser.parse_args()
public, private = generate()
values = {
"VAPID_PUBLIC_KEY": public,
"VAPID_PRIVATE_KEY": private,
"VAPID_SUBJECT": args.subject,
"%s_PUBLIC_KEY" % args.key_prefix: public,
"%s_PRIVATE_KEY" % args.key_prefix: private,
"%s_SUBJECT" % args.key_prefix: args.subject,
}
public_key = "%s_PUBLIC_KEY" % args.key_prefix
private_key = "%s_PRIVATE_KEY" % args.key_prefix
if args.write:
existing = read_env(args.file)
if (existing.get("VAPID_PUBLIC_KEY") or existing.get("VAPID_PRIVATE_KEY")) and not args.force:
if (existing.get(public_key) or existing.get(private_key)) and not args.force:
sys.exit("VAPID-Schlüssel sind in %s schon vorhanden (--force zum Ersetzen)." % args.file)
write_env(args.file, values)
print("Schlüssel in %s eingetragen." % args.file)