Add matrix_prometheus_container_network/matrix_prometheus_container_additional_networks
This commit is contained in:
@ -45,6 +45,11 @@
|
||||
owner: "{{ matrix_user_username }}"
|
||||
group: "{{ matrix_user_groupname }}"
|
||||
|
||||
- name: Ensure Prometheus container network is created
|
||||
community.general.docker_network:
|
||||
name: "{{ matrix_prometheus_container_network }}"
|
||||
driver: bridge
|
||||
|
||||
- name: Ensure matrix-prometheus.service installed
|
||||
ansible.builtin.template:
|
||||
src: "{{ role_path }}/templates/systemd/matrix-prometheus.service.j2"
|
||||
|
@ -5,3 +5,11 @@
|
||||
msg: >
|
||||
You need to enable `matrix_prometheus_scraper_synapse_enabled` and/or `matrix_prometheus_scraper_node_enabled` for Prometheus grab metrics.
|
||||
when: "not matrix_prometheus_scraper_synapse_enabled and not matrix_prometheus_scraper_node_enabled"
|
||||
|
||||
- name: Fail if required Prometheus settings not defined
|
||||
ansible.builtin.fail:
|
||||
msg: >
|
||||
You need to define a required configuration setting (`{{ item }}`).
|
||||
when: "vars[item] == ''"
|
||||
with_items:
|
||||
- matrix_prometheus_container_network
|
||||
|
Reference in New Issue
Block a user