π A simple bash script to automatically enable CF UAM when CPU load is high
Presentation β’ Installation β’ Requirements β’ License
CF-Auto-UAM is a simple bash script coming along with an automatic installer which will install everything for you.
CF-Auto-UAM installs two cronjobs :
- A cronjob which checks every 15 seconds for the CPU load and if it's higher than 10 it will enable CloudFlare Under Attack Mode.
- A cronjob which checks every 10-30 minutes for the CPU load and if it's lower than 10 it will disable CloudFlare Under Attack Mode.
cd cf-auto-uam
chmod 777 cf-auto-uam-install.sh
bash cf-auto-uam-install.sh
The installer will be asking for 3 things :
- Your CloudFlare email
- Your CloudFlare API key
- Your domain CloudFlare zone ID
The installer has been tested on Ubuntu 16.04, Debian 8, CentOS 7. If the installer doesn't work on other versions of those GNU please open an issue.
- Root Access
- Linux (Ubuntu/Debian/CentOS)
- CloudFlare Account
MIT