nouveau fichier : ap32-prod/zabbix-agent.sh

nouveau fichier : ap32-test/zabbix-agent.sh
This commit is contained in:
Adam Alphonso 2024-11-07 12:02:03 +01:00
parent 136c864ef7
commit 0c83a5b3ea
2 changed files with 20 additions and 0 deletions

10
ap32-prod/zabbix-agent.sh Normal file
View File

@ -0,0 +1,10 @@
#!/bin/bash
export http_proxy=http://10.121.38.1:8080
export https_proxy=https://10.121.38.1:8080
wget -4 https://repo.zabbix.com/zabbix/7.0/debian/pool/main/z/zabbix-release/zabbix-release_7.0-2+debian12_all.deb
dpkg -i zabbix-release_7.0-2+debian12_all.deb
apt install -y zabbix-agent2
echo "Server=172.16.0.112" >> /etc/zabbix/zabbix_agent2.conf
echo "ServerActive=172.16.0.112" >> /etc/zabbix/zabbix_agent2.conf
echo "Hostname=$(hostname)" >> /etc/zabbix/zabbix_agent2.conf
systemctl restart zabbix-agent2

10
ap32-test/zabbix-agent.sh Normal file
View File

@ -0,0 +1,10 @@
#!/bin/bash
export http_proxy=http://10.121.38.1:8080
export https_proxy=https://10.121.38.1:8080
wget -4 https://repo.zabbix.com/zabbix/7.0/debian/pool/main/z/zabbix-release/zabbix-release_7.0-2+debian12_all.deb
dpkg -i zabbix-release_7.0-2+debian12_all.deb
apt install -y zabbix-agent2
echo "Server=172.16.0.112" >> /etc/zabbix/zabbix_agent2.conf
echo "ServerActive=172.16.0.112" >> /etc/zabbix/zabbix_agent2.conf
echo "Hostname=$(hostname)" >> /etc/zabbix/zabbix_agent2.conf
systemctl restart zabbix-agent2