API-Doku (/docs, /redoc, /openapi.json) abschalten, Fedora-Kickstart-Endpunkt entfernen

Beides war über anode.tuxflotte.de ohne Anmeldung erreichbar (Durchsicht
18.10.2026, ADR-0046 Abschnitt 'Unabhängig davon'). Health-Check des
Deploys läuft seit infra 7c7069b über /health.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
adminandClaude Opus 5.5 committed 2026-10-18 18:20:14 +02:00
1 parent fc4e2c34b2
commit a7d22412b8
2 files changed
+8 -58

No files matched your search

+8 -11
View File
@@ -82,8 +82,7 @@ BOOT_MEDIUM_PATH = str(Path(
# zum Subprocess-cwd (TUXFLOTTE_INSTALLER_DIR) interpretiert, nicht relativ
# zum eigenen Arbeitsverzeichnis.
ISO_BUILD_OUTPUT_DIR = Path(os.environ.get("TUXFLOTTE_ISO_BUILD_OUTPUT_DIR", "data/iso-builds")).resolve()
# Golden Images (ADR-0024): bewusst unauthentifiziert, analog zu
# /installers/fedora-workstation/ks.cfg - werden von backend_launch()
# Golden Images (ADR-0024): bewusst unauthentifiziert - werden von backend_launch()
# per curl geladen, bevor das Zielgeraet irgendein Token besitzt. Kein
# personalisierter/kundenspezifischer Inhalt (anders als ISO-Builds oben),
# nur ein generisches Basis-Root-Dateisystem pro Distribution.
@@ -121,7 +120,13 @@ ISO_BUILD_TIMEOUT_SECONDS = 1800
ISO_BUILD_EXPIRY_DAYS = 7
ISO_BUILD_EXPIRY_SWEEP_INTERVAL_SECONDS = 60 * 60
app = FastAPI(title="Provisioning Activation Server", version="0.1.0")
# Keine automatische API-Doku (18.10.2026): /docs, /redoc und /openapi.json
# waren über anode.tuxflotte.de ohne Anmeldung erreichbar und beschrieben
# alle Endpunkte. Die Kundenplattform hat das schon seit 25.08. abgeschaltet.
app = FastAPI(
title="Provisioning Activation Server", version="0.1.0",
docs_url=None, redoc_url=None, openapi_url=None,
)
@app.on_event("startup")
@@ -7000,14 +7005,6 @@ def resolve_template(template_id: str, payload: ResolveRequest):
},
}
@app.get("/installers/fedora-workstation/ks.cfg")
def get_fedora_kickstart():
return FileResponse(
"installers/fedora-workstation/ks.cfg",
media_type="text/plain"
)
@app.get("/golden-images/{filename}")
def get_golden_image(filename: str):
# Path-Traversal-Schutz: Path(...).name kappt jeden "../"-Anteil, der