diff --git a/roles/munin-client/tasks/main.yml b/roles/munin-client/tasks/main.yml index b1262a7..eddc2f8 100644 --- a/roles/munin-client/tasks/main.yml +++ b/roles/munin-client/tasks/main.yml @@ -1,67 +1,69 @@ +--- + - set_fact: muninpkgs: - - muninlite - munin_need_reconfigure: False + - muninlite + munin_need_reconfigure: false when: ansible_facts['distribution'] == "LEDE" or ansible_facts['distribution'] == "OpenWRT" or ansible_facts['distribution'] == "OpenWrt" - set_fact: muninpkgs: - - munin-node - - munin-plugins-core - - munin-plugins-extra - munin_need_reconfigure: True + - munin-node + - munin-plugins-core + - munin-plugins-extra + munin_need_reconfigure: true when: ansible_facts['distribution'] == "Debian" - name: install munin node packages package: - name: "{{ item }}" - state: present + name: "{{ item }}" + state: present loop: "{{ muninpkgs }}" - name: munin-node conf file template: - src: munin-node.conf.j2 - dest: /etc/munin/munin-node.conf + src: munin-node.conf.j2 + dest: /etc/munin/munin-node.conf notify: - - restart munin-node + - restart munin-node when: munin_need_reconfigure ## Adding modules for specific functions # for NginX webservers - name: install LWP::UserAgent package: - name: libwww-perl - state: present + name: libwww-perl + state: present notify: - - restart munin-node + - restart munin-node when: "'webservers' in group_names or 'loadbalancers' in group_names" # for HAProxy servers - name: add HAProxy backend module file: - src: /usr/share/munin/plugins/haproxy_ - dest: /etc/munin/plugins/haproxy_current - state: link + src: /usr/share/munin/plugins/haproxy_ + dest: /etc/munin/plugins/haproxy_current + state: link notify: - - restart munin-node + - restart munin-node when: "'loadbalancers' in group_names" # For MariaDB servers - name: install Cache::Cache package: - name: libcache-cache-perl - state: present + name: libcache-cache-perl + state: present notify: - - restart munin-node + - restart munin-node when: "'mariadbservers' in group_names" # For PGSQL servers - name: install DBD::Pg package: - name: libdbd-pg-perl - state: present + name: libdbd-pg-perl + state: present notify: - - restart munin-node + - restart munin-node when: "'pgsqlservers' in group_names" # For Munin servers @@ -72,15 +74,15 @@ # for NUT (UPS) servers - name: "add specific nut value for UPS" file: - path: "/etc/munin/plugins/nutups_eaton3s_{{ item }}" - src: /usr/share/munin/plugins/nutups_ - state: link + path: "/etc/munin/plugins/nutups_eaton3s_{{ item }}" + src: /usr/share/munin/plugins/nutups_ + state: link notify: - - restart munin-node + - restart munin-node when: "'nut_server' in group_names" loop: - - charge - - voltages + - charge + - voltages # for physical servers - name: execute specific tasks for physical servers @@ -89,33 +91,34 @@ - name: reconfigure munin-node shell: - cmd: munin-node-configure --shell | sh + cmd: munin-node-configure --shell | sh notify: - - restart munin-node + - restart munin-node when: munin_need_reconfigure ## Useless junks for everyone - name: delete useless junks for everyone file: - path: "/etc/munin/plugins/{{ item }}" - state: absent + path: "/etc/munin/plugins/{{ item }}" + state: absent when: munin_need_reconfigure loop: - - users + - users ## Useless junks for LXC - name: "delete junks from LXC machines" file: - path: "/etc/munin/plugins/{{ item }}" - state: absent + path: "/etc/munin/plugins/{{ item }}" + state: absent notify: - - restart munin-node + - restart munin-node when: ansible_facts['virtualization_type'] == "lxc" loop: - - cpuspeed - - diskstats - - entropy - - irqstats + - acpi + - cpuspeed + - diskstats + - entropy + - irqstats ## Useless junks for hypervisors - name: execute delete states for hypervisors diff --git a/roles/spamassassin/files/local.cf b/roles/spamassassin/files/local.cf index 6358739..d1f712d 100644 --- a/roles/spamassassin/files/local.cf +++ b/roles/spamassassin/files/local.cf @@ -113,6 +113,7 @@ whitelist_from *@chichiclothing.com whitelist_from dmarcreport@microsoft.com # Blacklist manuel +blacklist_from *@*.org.ru blacklist_from *@basretion.eu blacklist_from *@appleawhite.ru blacklist_from *@apolnews.fr