Signed-off-by: Boris Ranto <branto@redhat.com>
- /etc/grafana
- /var/lib/grafana
+- name: Make sure the grafana-server service is down
+ service:
+ name: grafana-server
+ state: stopped
+ failed_when: false
+
- name: Create docker container
docker_container:
name: grafana-server
# restart to allow updates
restart: true
restart_policy: no
+ force_kill: yes
published_ports: '3000:3000'
detach: true
volumes:
include_role:
name: ceph-docker
allow_duplicates: false
+ when: containerized
+
+- name: Make sure the node_exporter service is down
+ service:
+ name: node_exporter
+ state: stopped
+ failed_when: false
- name: Start docker container
docker_container:
name: node-exporter
image: "{{ node_exporter.container_image }}"
+ state: started
command:
- '--path.procfs=/host/proc'
- '--path.sysfs=/host/sys'
- '--no-collector.timex'
+ # restart to allow updates
+ restart: true
restart_policy: no
+ force_kill: yes
detach: true
volumes:
- '/proc:/host/proc:ro'
allow_duplicates: false
when: containerized
+- name: Make sure the prometheus service is down
+ service:
+ name: prometheus
+ state: stopped
+ failed_when: false
+
- name: Start docker container
docker_container:
name: prometheus
image: "{{ prometheus.container_image }}"
+ state: started
command: "--config.file=/prometheus/prometheus.yml"
+ # restart to allow updates
+ restart: true
restart_policy: no
+ force_kill: yes
published_ports: '9090:9090'
detach: true
volumes: