add prometheus_server tags

This commit is contained in:
Ludovic Cartier 2022-11-16 11:47:48 +01:00
parent dab6c43169
commit 7129db1a50

View File

@ -3,29 +3,25 @@
assert: assert:
that: that:
- "prometheus_server_monitor is defined" - "prometheus_server_monitor is defined"
tags: tags: ['prometheus_server']
- prometheus
- name: 'prometheus | server | create docker network' - name: 'prometheus | server | create docker network'
docker_network: docker_network:
name: 'prometheus' name: 'prometheus'
tags: tags: ['prometheus_server']
- prometheus
- name: 'prometheus | server | create docker volume data' - name: 'prometheus | server | create docker volume data'
docker_volume: docker_volume:
name: prometheus_data name: prometheus_data
register: register_docker_volume_prometheus__prometheus_data register: register_docker_volume_prometheus__prometheus_data
tags: tags: ['prometheus_server']
- prometheus
- name: 'prometheus | server | create prometheus directory to /etc' - name: 'prometheus | server | create prometheus directory to /etc'
file: file:
path: /etc/prometheus path: /etc/prometheus
state: directory state: directory
mode: '0755' mode: '0755'
tags: tags: ['prometheus_server']
- prometheus
- name: 'prometheus | server | copy config prometheus yml' - name: 'prometheus | server | copy config prometheus yml'
template: template:
@ -34,8 +30,7 @@
owner: root owner: root
group: root group: root
mode: 0644 mode: 0644
tags: tags: ['prometheus_server']
- prometheus
notify: notify:
- 'prometheus | server | restart container' - 'prometheus | server | restart container'
@ -64,7 +59,6 @@
restart_policy: 'unless-stopped' restart_policy: 'unless-stopped'
pull: '{{ prometheus_docker_pull }}' pull: '{{ prometheus_docker_pull }}'
etc_hosts: '{{ prometheus_nodes_ip }}' etc_hosts: '{{ prometheus_nodes_ip }}'
tags: tags: ['prometheus_server']
- prometheus
notify: notify:
- 'prometheus | server | restart container' - 'prometheus | server | restart container'