diff --git a/roles/synapse/README.md b/roles/synapse/README.md index 1f401dd..b579c03 100644 --- a/roles/synapse/README.md +++ b/roles/synapse/README.md @@ -50,6 +50,7 @@ If deploying synapse in a docker container, check that you have `docker` and the | `matrix_synapse_redis_host` | _None_ | host on which redis is running | | `matrix_synapse_redis_port` | 6379 | port on which redis is running | | `matrix_synapse_redis_pass` | _None_ | password to use to authentificate to redis | +| `matrix_synapse_metrics_enabled` | `false` | If prometheus metrics should be enabled. | ### Worker control variables diff --git a/roles/synapse/defaults/main.yml b/roles/synapse/defaults/main.yml index 05f5532..bbdab7c 100644 --- a/roles/synapse/defaults/main.yml +++ b/roles/synapse/defaults/main.yml @@ -38,11 +38,13 @@ matrix_synapse_redis_host: ~ matrix_synapse_redis_port: 6379 matrix_synapse_redis_pass: ~ +# Monitoring +matrix_synapse_metrics_enabled: false +matrix_synapse_worker_metrics_enabled: "{{ matrix_synapse_metrics_enabled | bool }}" +matrix_synapse_worker_metrics_port: 9101 # Worker control config matrix_synapse_workers_enabled: false -matrix_synapse_worker_metrics_enabled: false -matrix_synapse_worker_metrics_port: 9101 matrix_synapse_worker_replication_host: "{{ matrix_synapse_container_name }}" matrix_synapse_worker_replication_port: 9003 matrix_synapse_worker_replication_bind_ip: "127.0.0.1" diff --git a/roles/synapse/vars/main.yml b/roles/synapse/vars/main.yml index 062e054..7815899 100644 --- a/roles/synapse/vars/main.yml +++ b/roles/synapse/vars/main.yml @@ -143,7 +143,7 @@ matrix_synapse_base_config: - matrix.org - vector.im autocreate_auto_join_rooms: true - enable_metrics: False + enable_metrics: "{{ matrix_synapse_metrics_enabled }}" report_stats: "{{ matrix_synapse_report_stats }}" app_service_config_files: [] track_appservice_user_ips: False