Skip to content

Commit

Permalink
use debugger variable to enable only debugger without debug mode enabled
Browse files Browse the repository at this point in the history
Signed-off-by: Jens Langhammer <[email protected]>
  • Loading branch information
BeryJu committed Jan 26, 2025
1 parent f91d6ce commit 1262919
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion authentik/lib/debug.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
def start_debug_server(**kwargs) -> bool:
"""Attempt to start a debugpy server in the current process.
Returns true if the server was started successfully, otherwise false"""
if not CONFIG.get_bool("debug"):
if not CONFIG.get_bool("debug") and not CONFIG.get_bool("debugger"):
return
try:
import debugpy
Expand Down
1 change: 1 addition & 0 deletions authentik/lib/default.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ cache:
# transport_options: ""

debug: false
debugger: false

log_level: info

Expand Down
2 changes: 1 addition & 1 deletion lifecycle/ak
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ function prepare_debug {
chown authentik:authentik /unittest.xml
}

if [[ "$(python -m authentik.lib.config debug 2> /dev/null)" == "True" ]]; then
if [[ "$(python -m authentik.lib.config debugger 2> /dev/null)" == "True" ]]; then
prepare_debug
fi

Expand Down

0 comments on commit 1262919

Please sign in to comment.