---

### tags:

- name: "Deploy service templates for {{ inventory_hostname }}"
  include_role:
    name: sma_deploy
    tasks_from: templates
  vars:
    current_config: "prometheus"
    current_base_path: "{{ service_base_path }}"
    current_destination: "{{ inventory_hostname }}"
    current_owner: "{{ docker_owner }}"
    current_group: "{{ docker_group }}"

- name: "Reload prometheus configuration"
  uri:
    url: "{{ http_s }}://{{ prometheus_id }}.{{ domain }}/-/reload"
    method: POST
    timeout: 300 # blocks until reload configuration is complete
    status_code: 200
