umbau 1.2

This commit is contained in:
2026-09-03 00:51:01 +02:00
parent 8b0c35fc8b
commit 685068c21b
3 changed files with 31 additions and 3 deletions

View File

@ -419,6 +419,20 @@ async def rdp_tunnel(
host, password.decode(), session_id=session_id, username=cred_row[1], domain=cred_row[2],
client_name=f"jumphost-{user.username}", timezone=safe_timezone,
)
if host.get("file_transfer_enabled"):
# Bug-Fix (Live-Test, RDP-Teilstrecke, 2.9.): guacd/FreeRDPs
# "create-drive-path" legt nur das BLATT-Verzeichnis an, keine
# fehlenden Elternverzeichnisse (kein "mkdir -p"). Bisher wurde
# ausschliesslich data_dir/recordings_dir beim Start angelegt
# (siehe app/db.py) -- das Elternverzeichnis .../rdp-drives/<host_id>/
# existierte fuer einen frischen Host nie, wodurch guacd mit
# "Unable to create directory ... No such file or directory"
# abbrach. Deshalb hier explizit VOR dem Tunnelaufbau mit
# parents=True anlegen (blockierendes Datei-I/O -> Thread, wie
# bei _cleanup_rdp_drive_path()).
await asyncio.to_thread(
rdp_drive_path(host_id, session_id).mkdir, parents=True, exist_ok=True
)
tunnel = await open_tunnel(
guacd_host=settings.guacd_host, guacd_port=settings.guacd_port,
protocol="rdp", params=params, screen_width=width, screen_height=height, dpi=dpi,