lifecycle: much improved debugging experience (#12804)

* lifecycle: much improved debugging experience

Signed-off-by: Jens Langhammer <jens@goauthentik.io>

* format

Signed-off-by: Jens Langhammer <jens@goauthentik.io>

* add start debug launch configs

Signed-off-by: Jens Langhammer <jens@goauthentik.io>

* only install dev deps in container

Signed-off-by: Jens Langhammer <jens@goauthentik.io>

* add pathMappings

Signed-off-by: Jens Langhammer <jens@goauthentik.io>

* use debugger variable to enable only debugger without debug mode enabled

Signed-off-by: Jens Langhammer <jens@goauthentik.io>

* fix path map

Signed-off-by: Jens Langhammer <jens@goauthentik.io>

---------

Signed-off-by: Jens Langhammer <jens@goauthentik.io>
This commit is contained in:
Jens L.
2025-02-01 03:35:56 +01:00
committed by GitHub
parent 7c944b954c
commit 334e2c466f
10 changed files with 103 additions and 25 deletions

View File

@ -13,6 +13,7 @@ from prometheus_client.values import MultiProcessValue
from authentik import get_full_version
from authentik.lib.config import CONFIG
from authentik.lib.debug import start_debug_server
from authentik.lib.logging import get_logger_config
from authentik.lib.utils.http import get_http_session
from authentik.lib.utils.reflection import get_env
@ -146,9 +147,5 @@ if not CONFIG.get_bool("disable_startup_analytics", False):
except Exception: # nosec
pass
if CONFIG.get_bool("remote_debug"):
import debugpy
debugpy.listen(("0.0.0.0", 6800)) # nosec
start_debug_server()
run_migrations()