--- - name: "Monitoring | Enable Modules" community.general.apache2_module: name: status state: present notify: reload apache2 - name: "Monitoring | Copy configuration" ansible.builtin.copy: src: server-status.conf dest: /etc/apache2/sites-available/server-status.conf mode: 0644 - name: "Monitoring | Enable localhost site configuration" ansible.builtin.command: cmd: a2ensite server-status creates: /etc/apache2/sites-enabled/server-status.conf notify: reload apache2 - name: "Monitoring | Copy munin configuration" ansible.builtin.template: src: munin_configuration dest: /etc/munin/plugin-conf.d/yyy-apache mode: 0644 notify: restart munin-node - name: "Mpnitoring | Enable Munin plugins" ansible.builtin.file: src: "/usr/share/munin/plugins/{{ item }}" dest: "/etc/munin/plugins/{{ item }}" state: link loop: - apache_accesses - apache_processes - apache_volume notify: restart munin-node