Skip to content

Commit 5f77900

Browse files
author
SilviaAmAm
committed
🚸 [#857] Adding logging with configurable level for OIDC
1 parent 866fbd2 commit 5f77900

1 file changed

Lines changed: 10 additions & 2 deletions

File tree

  • backend/src/openarchiefbeheer/conf

backend/src/openarchiefbeheer/conf/base.py

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -244,8 +244,11 @@
244244
# LOGGING
245245
#
246246
LOG_STDOUT = config("LOG_STDOUT", default=False)
247-
248247
LOGGING_DIR = BASE_DIR / "log"
248+
LOG_LEVEL = config(
249+
"LOG_LEVEL",
250+
default="INFO",
251+
)
249252

250253
LOGGING = {
251254
"version": 1,
@@ -306,7 +309,7 @@
306309
"loggers": {
307310
"openarchiefbeheer": {
308311
"handlers": ["project"] if not LOG_STDOUT else ["console"],
309-
"level": "INFO",
312+
"level": LOG_LEVEL,
310313
"propagate": True,
311314
},
312315
"django.request": {
@@ -319,6 +322,11 @@
319322
"level": "INFO",
320323
"propagate": True,
321324
},
325+
"mozilla_django_oidc_db": {
326+
"handlers": ["console"],
327+
"level": LOG_LEVEL,
328+
"propagate": True,
329+
},
322330
},
323331
}
324332

0 commit comments

Comments
 (0)