--- # node_exporter, cAdvisor and Alloy on every host. Metrics listen on the # host's VPC address only; Alloy ships Docker logs and the journal to Loki # on asxpio-ops over the VPC. - name: Create the node_exporter textfile directory ansible.builtin.file: path: "{{ monitoring_textfile_dir }}" state: directory mode: "0755" - name: Deploy the monitoring agents ansible.builtin.include_role: name: docker_service vars: service_name: monitoring-agent service_base_path: "{{ services_base_path }}/monitoring-agent" service_templates: - { src: docker-compose.yml.j2, dest: docker-compose.yml } - { src: config.alloy.j2, dest: config.alloy } health_check_enabled: true health_check_host: "{{ vpc_ip }}" health_check_port: "{{ monitoring_node_exporter_port }}"