mirror of
https://github.com/spantaleev/matrix-docker-ansible-deploy.git
synced 2024-11-17 12:44:53 +00:00
8ebf18a885
* add prometheus-nginxlog-exporter role * Rename matrix_prometheus_nginxlog_exporter_container_url to matrix_prometheus_nginxlog_exporter_container_hostname * avoid referencing variables from other roles, handover info using group_vars/matrix_servers * fix: stop service when uninstalling fix: typo move available arch's into a var fix: text * fix: prometheus enabled condition Co-authored-by: ikkemaniac <ikkemaniac@localhost>
37 lines
1.3 KiB
Django/Jinja
37 lines
1.3 KiB
Django/Jinja
listen:
|
|
port: {{ matrix_prometheus_nginxlog_exporter_container_metrics_port }}
|
|
address: "0.0.0.0"
|
|
metrics_endpoint: "/metrics"
|
|
|
|
namespaces:
|
|
- name: matrix
|
|
metrics_override:
|
|
preffix: "myprefix"
|
|
namespace_label: "namespace"
|
|
format: "$log_source $server_name - $upstream_addr - $remote_addr - $remote_user [$time_local] $host \"$request\" $status \"$http_referer\" \"$http_user_agent\" \"$http_x_forwarded_for\""
|
|
# enable to print to console
|
|
# print_log: true
|
|
source:
|
|
syslog:
|
|
listen_address: "udp://0.0.0.0:{{ matrix_prometheus_nginxlog_exporter_container_syslog_port }}"
|
|
# format options: "rfc3164" ,"rfc5424", "rfc6587", "auto"
|
|
format: auto
|
|
tags: ["matrix_nginx_proxy", "matrix_nginx_proxy_companion"]
|
|
relabel_configs:
|
|
- target_label: request_uri
|
|
from: request
|
|
split: 2
|
|
separator: ' '
|
|
matches:
|
|
- regexp: "^([^\\?]+)(.*)"
|
|
replacement: "$1"
|
|
- target_label: remote_addr
|
|
from: remote_addr
|
|
- target_label: server_name
|
|
from: server_name
|
|
- target_label: http_x_forwarded_for
|
|
from: http_x_forwarded_for
|
|
- target_label: request_host
|
|
from: host
|
|
- target_label: log_source
|
|
from: log_source |