Verified Commit b59d6b99 authored by Florian Pritz's avatar Florian Pritz
Browse files

Add cpu/memory accounting to many roles


Signed-off-by: Florian Pritz's avatarFlorian Pritz <bluewind@xinu.at>
parent 0718953b
......@@ -61,3 +61,6 @@
- name: activate systemd timers for backup
service: name=borg-backup.timer enabled=yes state=started
- name: enable systemd ressource accounting
command: systemctl set-property borg-backup CPUAccounting=yes MemoryAccounting=yes
......@@ -6,3 +6,6 @@
- name: activate cronie.service
service: name=cronie enabled=yes state=started
- name: enable systemd ressource accounting
command: systemctl set-property cronie CPUAccounting=yes MemoryAccounting=yes
......@@ -17,3 +17,6 @@
- name: start and enable dovecot
service: name=dovecot enabled=yes state=started
- name: enable systemd ressource accounting
command: systemctl set-property dovecot CPUAccounting=yes MemoryAccounting=yes
......@@ -21,3 +21,6 @@
- name: start and enable service
service: name=grafana state=started enabled=true
- name: enable systemd ressource accounting
command: systemctl set-property grafana CPUAccounting=yes MemoryAccounting=yes
......@@ -15,6 +15,9 @@
- name: start and enable the service
service: name=mariadb state=started enabled=yes
- name: enable systemd ressource accounting
command: systemctl set-property mariadb CPUAccounting=yes MemoryAccounting=yes
- name: delete anonymous users
mysql_user: user='' host_all=yes state='absent'
......
......@@ -149,3 +149,9 @@
with_items:
- synapse.service
- matrix-appservice-irc.service
- name: enable systemd ressource accounting
command: systemctl set-property {{item}} CPUAccounting=yes MemoryAccounting=yes
with_items:
- synapse
- matrix-appservice-irc
......@@ -65,3 +65,6 @@
- name: enable nginx
service: name=nginx enabled=yes
- name: enable systemd ressource accounting
command: systemctl set-property nginx CPUAccounting=yes MemoryAccounting=yes
......@@ -32,3 +32,6 @@
- name: start and enable opendkim
service: name=opendkim enabled=yes state=started
- name: enable systemd ressource accounting
command: systemctl set-property opendkim CPUAccounting=yes MemoryAccounting=yes
......@@ -40,3 +40,6 @@
service: name={{ item }} enabled=yes state=started
with_items:
- planet.timer
- name: enable systemd ressource accounting
command: systemctl set-property planet CPUAccounting=yes MemoryAccounting=yes
......@@ -62,6 +62,9 @@
- name: start and enable postfix
service: name=postfix enabled=yes state=started
- name: enable systemd ressource accounting
command: systemctl set-property postfix CPUAccounting=yes MemoryAccounting=yes
- name: remove old files
file: path={{item}} state=absent
with_items:
......
......@@ -11,4 +11,7 @@
- name: start and enable postfwd
service: name=postfwd enabled=yes state=started
- name: enable systemd ressource accounting
command: systemctl set-property postfwd CPUAccounting=yes MemoryAccounting=yes
......@@ -65,3 +65,6 @@
- oidentd.socket
- quassel.service
- clean-quassel.timer
- name: enable systemd ressource accounting
command: systemctl set-property quassel CPUAccounting=yes MemoryAccounting=yes
......@@ -69,3 +69,6 @@
- name: start and enable security-tracker timer
service: name="security-tracker-update.timer" enabled=yes state=started
- name: enable systemd ressource accounting
command: systemctl set-property security-tracker-update CPUAccounting=yes MemoryAccounting=yes
......@@ -19,3 +19,6 @@
- name: start and enable sogrep units
service: name=createlinks.timer enabled=yes state=started
- name: enable systemd ressource accounting
command: systemctl set-property createlinks CPUAccounting=yes MemoryAccounting=yes
......@@ -49,3 +49,6 @@
- name: start spampd
service: name=spampd enabled=yes state=started
- name: enable systemd ressource accounting
command: systemctl set-property spampd CPUAccounting=yes MemoryAccounting=yes
......@@ -16,3 +16,6 @@
- name: start and enable sshd
service: name=sshd enabled=yes state=started
- name: enable systemd ressource accounting
command: systemctl set-property sshd CPUAccounting=yes MemoryAccounting=yes
......@@ -27,6 +27,9 @@
- syncrepo.timer
- rsyncd.socket
- name: enable systemd ressource accounting
command: systemctl set-property system-rsyncd.slice CPUAccounting=yes MemoryAccounting=yes
- name: set local mirror as cachedir
lineinfile:
dest: /etc/pacman.conf
......
......@@ -13,3 +13,6 @@
- name: Active service
service: name=unbound state=started enabled=yes
- name: enable systemd ressource accounting
command: systemctl set-property unbound CPUAccounting=yes MemoryAccounting=yes
......@@ -46,6 +46,12 @@
service: name=nginx-zabbix.service enabled=yes state=started
when: "'nginx' in group_names"
- name: enable systemd ressource accounting
command: systemctl set-property nginx-zabbix CPUAccounting=yes MemoryAccounting=yes
when: "'nginx' in group_names"
- name: run zabbix agent service
service: name=zabbix-agent enabled=yes state=started
- name: enable systemd ressource accounting
command: systemctl set-property zabbix-agent CPUAccounting=yes MemoryAccounting=yes
......@@ -63,5 +63,8 @@
- name: start and enable systemd socket
service: name=php-fpm@zabbix-web.socket state=started enabled=true
- name: enable systemd ressource accounting
- name: enable systemd ressource accounting php-fpm
command: systemctl set-property php-fpm@zabbix-web CPUAccounting=yes MemoryAccounting=yes
- name: enable systemd ressource accounting zabbix-server
command: systemctl set-property zabbix-server-pgsql CPUAccounting=yes MemoryAccounting=yes
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment