icinga2-checks/install.sh

20 lines
751 B
Bash
Raw Normal View History

2023-04-21 23:54:18 -06:00
#!/bin/bash
2023-04-21 23:54:18 -06:00
# apt update && apt install -y git && cd /opt && git -C /opt/icinga2-checks pull || git clone https://git.dp15.us/dpanzer/icinga2-checks.git /opt/icinga2-checks && bash /opt/icinga2-checks/install.sh
# @hourly /bin/bash /opt/icinga2-checks/install.sh
2023-04-21 23:54:18 -06:00
apt update
2023-04-21 23:54:19 -06:00
apt install -y python3-venv git sysstat bc
2023-04-21 23:54:18 -06:00
2023-04-21 23:54:18 -06:00
pip install psutil
2023-04-21 23:54:18 -06:00
#cd /opt || exit
2023-04-21 23:54:18 -06:00
git -C /opt/icinga2-checks pull || git clone https://git.dp15.us/dpanzer/icinga2-checks.git /opt/icinga2-checks
ln -s /opt/icinga2-checks/check_iowait.sh /usr/lib64/nagios/plugins/check_iowait
2023-04-21 23:54:19 -06:00
ln -s /opt/icinga2-checks/check_bandwidth /usr/lib64/nagios/plugins/check_bandwidth
rm /usr/lib64/nagios/plugins/check_curl
ln -s /opt/icinga2-checks/check_curl /usr/lib64/nagios/plugins/check_curl