Moved roles to subdirectory

This commit is contained in:
2020-01-03 16:37:00 +01:00
parent a8cca4f575
commit ec4e0d3b96
25 changed files with 0 additions and 0 deletions
@@ -0,0 +1,15 @@
#!/bin/sh
# Check disk space
CURRENT=$(df / --output=pcent | tail --lines=1 | cut --delimiter='%' --field=1)
THRESHOLD=90
ADMIN="root@{{ ansible_domain }}"
SUBJECT="[Disk Space Alert] The free space on {{ ansible_fqdn }} is critically low"
MESSAGE=
if [ "$CURRENT" -gt "$THRESHOLD" ]; then
mail -s "$SUBJECT" "$ADMIN" << EOF
Your root partition remaining free space is critically low. Used: $CURRENT%
EOF
fi