diff options
author | Shane McDonald <me@shanemcd.com> | 2021-04-02 20:16:51 +0200 |
---|---|---|
committer | Shane McDonald <me@shanemcd.com> | 2021-04-02 20:16:51 +0200 |
commit | fccfef442c22a99ac2ac439b2dc6ed25bc2cfa0f (patch) | |
tree | ac6bda8697e5fc917938e9ee5f671c4bd232038d /tools/docker-compose/supervisor.conf | |
parent | Merge pull request #9737 from jlmitch5/workflowConvergence (diff) | |
download | awx-fccfef442c22a99ac2ac439b2dc6ed25bc2cfa0f.tar.xz awx-fccfef442c22a99ac2ac439b2dc6ed25bc2cfa0f.zip |
Make logs more readable in development environment
This uses https://github.com/coderanger/supervisor-stdout to prefix process
names before log messages in the dev env
Diffstat (limited to 'tools/docker-compose/supervisor.conf')
-rw-r--r-- | tools/docker-compose/supervisor.conf | 39 |
1 files changed, 23 insertions, 16 deletions
diff --git a/tools/docker-compose/supervisor.conf b/tools/docker-compose/supervisor.conf index fc2eb2d028..9d0cd4ded3 100644 --- a/tools/docker-compose/supervisor.conf +++ b/tools/docker-compose/supervisor.conf @@ -12,8 +12,9 @@ stopsignal=KILL stopasgroup=true killasgroup=true redirect_stderr=true -stdout_logfile=/dev/fd/1 -stdout_logfile_maxbytes=0 +stdout_events_enabled = true +stderr_events_enabled = true + [program:awx-receiver] command = make receiver @@ -24,8 +25,8 @@ stopsignal=KILL stopasgroup=true killasgroup=true redirect_stderr=true -stdout_logfile=/dev/fd/1 -stdout_logfile_maxbytes=0 +stdout_events_enabled = true +stderr_events_enabled = true [program:awx-wsbroadcast] command = make wsbroadcast @@ -36,8 +37,8 @@ stopsignal=KILL stopasgroup=true killasgroup=true redirect_stderr=true -stdout_logfile=/dev/fd/1 -stdout_logfile_maxbytes=0 +stdout_events_enabled = true +stderr_events_enabled = true [program:awx-uwsgi] command = make uwsgi @@ -48,8 +49,8 @@ stopwaitsecs = 1 stopsignal=KILL stopasgroup=true killasgroup=true -stdout_logfile=/dev/fd/1 -stdout_logfile_maxbytes=0 +stdout_events_enabled = true +stderr_events_enabled = true [program:awx-daphne] command = make daphne @@ -60,16 +61,16 @@ stopwaitsecs = 1 stopsignal=KILL stopasgroup=true killasgroup=true -stdout_logfile=/dev/fd/1 -stdout_logfile_maxbytes=0 +stdout_events_enabled = true +stderr_events_enabled = true [program:awx-nginx] command = make nginx autostart = true autorestart = true redirect_stderr=true -stdout_logfile=/dev/fd/1 -stdout_logfile_maxbytes=0 +stdout_events_enabled = true +stderr_events_enabled = true [program:awx-rsyslogd] command = rsyslogd -n -i /var/run/awx-rsyslog/rsyslog.pid -f /var/lib/awx/rsyslog/rsyslog.conf @@ -80,8 +81,8 @@ stopsignal=TERM stopasgroup=true killasgroup=true redirect_stderr=true -stdout_logfile=/dev/fd/1 -stdout_logfile_maxbytes=0 +stdout_events_enabled = true +stderr_events_enabled = true [program:awx-receptor] command = receptor --config /etc/receptor/receptor.conf @@ -91,8 +92,8 @@ stopsignal = KILL stopasgroup = true killasgroup = true redirect_stderr=true -stdout_logfile=/dev/fd/1 -stdout_logfile_maxbytes=0 +stdout_events_enabled = true +stderr_events_enabled = true [group:tower-processes] programs=awx-dispatcher,awx-receiver,awx-uwsgi,awx-daphne,awx-nginx,awx-wsbroadcast,awx-rsyslogd @@ -106,3 +107,9 @@ serverurl=unix:///var/run/supervisor/supervisor.sock ; use a unix:// URL for a [rpcinterface:supervisor] supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface + +[eventlistener:stdout] +command = supervisor_stdout +buffer_size = 100 +events = PROCESS_LOG +result_handler = supervisor_stdout:event_handler |