Add SNMP package

pull/111/head^2
DiouxX 7 years ago
parent c160bc51b7
commit 58ff53e00b

@ -25,7 +25,8 @@ php-apcu-bc \
php-cas \
cron \
wget \
jq
jq \
snmpd
#Copie et execution du script pour l'installation et l'initialisation de GLPI
COPY glpi-start.sh /opt/

@ -34,13 +34,25 @@ fi
#Modification du vhost par défaut
echo -e "<VirtualHost *:80>\n\tDocumentRoot /var/www/html/glpi\n\n\t<Directory /var/www/html/glpi>\n\t\tAllowOverride All\n\t\tOrder Allow,Deny\n\t\tAllow from all\n\t</Directory>\n\n\tErrorLog /var/log/apache2/error-glpi.log\n\tLogLevel warn\n\tCustomLog /var/log/apache2/access-glpi.log combined\n</VirtualHost>" > /etc/apache2/sites-available/000-default.conf
#Activation du module rewrite d'apache
a2enmod rewrite && service apache2 restart && service apache2 stop
######################
# CRON CONFIGURATION #
######################
#Add scheduled task by cron and enable
echo "*/2 * * * * www-data /usr/bin/php /var/www/html/glpi/front/cron.php &>/dev/null" >> /etc/cron.d/glpi
#Start cron service
service cron start
#Activation du module rewrite d'apache
a2enmod rewrite && service apache2 restart && service apache2 stop
######################
# SNMP CONFIGURATION #
######################
#Replace Listen localhot SNMP and restart service
sed -ie "s/agentAddress udp:127.0.0.1:161/agentAdrress udp:161/g" /etc/snmp/snmpd.conf
service snmpd restart
#Lancement du service apache au premier plan
/usr/sbin/apache2ctl -D FOREGROUND

Loading…
Cancel
Save