mirror of
https://github.com/spantaleev/matrix-docker-ansible-deploy.git
synced 2026-04-18 14:45:58 +00:00
matrix-synapse: add routing-focused reverse-proxy access log preset
This commit is contained in:
@@ -48,12 +48,14 @@ http {
|
||||
js_shared_dict_zone zone=whoami_sync_worker_router_cache:{{ matrix_synapse_reverse_proxy_companion_whoami_sync_worker_router_cache_size_mb }}m;
|
||||
{% endif %}
|
||||
|
||||
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
|
||||
'$status $body_bytes_sent "$http_referer" '
|
||||
'"$http_user_agent" "$http_x_forwarded_for"';
|
||||
{% set access_log_format_fragments = matrix_synapse_reverse_proxy_companion_access_log_format_presets[matrix_synapse_reverse_proxy_companion_access_log_format] %}
|
||||
log_format access_log_fmt
|
||||
{% for fragment in access_log_format_fragments %}
|
||||
'{{ fragment }}'{% if loop.last %};{% endif %}
|
||||
{% endfor %}
|
||||
|
||||
{% if matrix_synapse_reverse_proxy_companion_access_log_enabled %}
|
||||
access_log /var/log/nginx/access.log main;
|
||||
access_log /var/log/nginx/access.log access_log_fmt;
|
||||
{% else %}
|
||||
access_log off;
|
||||
{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user