Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
lava
lava
Commits
bdea8be9
Commit
bdea8be9
authored
Jun 01, 2022
by
Igor Ponomarev
Committed by
Paweł Wieczorek
Jul 06, 2022
Browse files
docker/collabora: Use JSON logging
parent
4a96ca15
Changes
3
Hide whitespace changes
Inline
Side-by-side
docker/collabora/Dockerfile
View file @
bdea8be9
...
...
@@ -34,6 +34,9 @@ RUN apt update && \
wait-for-it
&&
\
rm
/
*
deb
# Logging env
COPY
docker/collabora/logging_env.yaml /
# We use configuration from the environment, not an env file, but we need this empty file
# to silence a warning from django-environ.
RUN
touch
/usr/lib/python3/dist-packages/lava_server/settings/.env
...
...
docker/collabora/logging_env.yaml
0 → 100644
View file @
bdea8be9
LOGGING
:
version
:
1
disable_existing_loggers
:
True
filters
:
require_debug_false
:
()
:
django.utils.log.RequireDebugFalse
formatters
:
json_formatter
:
()
:
lava_common.logging_utils.json_formatter
extra_keys
:
-
sql
-
duration
-
alias
handlers
:
console
:
class
:
logging.StreamHandler
formatter
:
json_formatter
level
:
DEBUG
loggers
:
django
:
handlers
:
-
console
level
:
ERROR
propagate
:
False
django_auth_ldap
:
handlers
:
-
console
level
:
INFO
propagate
:
False
lava_results_app
:
handlers
:
-
console
level
:
INFO
propagate
:
False
lava_scheduler_app
:
handlers
:
-
console
level
:
INFO
propagate
:
False
lava-scheduler
:
handlers
:
-
console
level
:
DEBUG
propagate
:
False
lava-publisher
:
handlers
:
-
console
level
:
DEBUG
propagate
:
False
docker/collabora/start-lava.sh
View file @
bdea8be9
...
...
@@ -9,6 +9,7 @@ DATABASE=`python3 -c 'import os; from urllib.parse import urlparse; url = urlpar
# Make sure configuration directories are available and have the appropriate
# ownership and permissions.
mkdir
-p
/etc/lava-server/settings.d
cp
/logging_env.yaml /etc/lava-server/settings.d
mkdir
-p
/etc/lava-server/dispatcher.d
chown
-R
lavaserver: /etc/lava-server/dispatcher.d
...
...
@@ -36,10 +37,10 @@ if [ -z $LOGLEVEL ]; then
LOGLEVEL
=
DEBUG
fi
/usr/bin/lava-server manage lava-publisher
--level
$LOGLEVEL
--log-file
-
--host
'*'
--port
8001 &
/usr/bin/lava-server manage lava-publisher
--host
'*'
--port
8001 &
while
:
;
do
/usr/bin/lava-server manage lava-scheduler
--level
$LOGLEVEL
--log-file
-
$EVENT_URL
$IPV6
/usr/bin/lava-server manage lava-scheduler
$EVENT_URL
$IPV6
done
&
if
[
-z
$WORKERS
]
;
then
...
...
@@ -54,4 +55,4 @@ if [ -z $BIND ]; then
BIND
=
"--bind 0.0.0.0:8000"
fi
exec
/usr/bin/gunicorn3 lava_server.wsgi
--log-level
$LOGLEVEL
--log-file
-
-u
lavaserver
-g
lavaserver
--worker-class
$WORKER_CLASS
--workers
$WORKERS
$BIND
$RELOAD
$TIMEOUT
exec
/usr/bin/gunicorn3 lava_server.wsgi
-u
lavaserver
-g
lavaserver
--worker-class
$WORKER_CLASS
--workers
$WORKERS
$BIND
$RELOAD
$TIMEOUT
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment