initial commit

This commit is contained in:
Ansible Servercow
2024-11-19 16:04:17 +01:00
commit 67c5aae913
26 changed files with 438 additions and 0 deletions

View File

@@ -0,0 +1,9 @@
- name: Run disk space command
ansible.builtin.shell: "df --output=used,avail / | awk 'NR==2 {used=$1; available=$2; total=used+available; percentage=used*100/total; if (percentage < {{ disk_space_percent_max }} ) printf \"true\"; else printf \"false\"}'"
# System uses the disk_space_percent_max variable to determine condition this check is getting. Over the amount defined in the var causes the check to fail!
register: disk_space_output
- name: "**DEBUG**: Server disk Utilization condition"
ansible.builtin.debug:
var: disk_space_output.stdout
when: debug | bool