Permalink
Browse files

Update MOTD ASCII logo for NEMS 1.5

  • Loading branch information...
NEMS Linux
NEMS Linux committed Nov 6, 2018
1 parent a430d50 commit f2e4bf578cb51554541693edf2687a0d8bde53cf
Showing with 14 additions and 15 deletions.
  1. +9 −12 build/052-nems-nagios-plugins
  2. +5 −3 build/150-nems
@@ -1,27 +1,24 @@
#!/bin/bash
# Dependencies
# CISCO
apt -y install libnet-snmp-perl snmp
# WMIC
apt -y install libdatetime-timezone-perl
# Setup an interpreter for notify-by-pushover (and possibly others... prevents problems)
if [[ ! -f /usr/local/bin/php ]]; then
if [[ -f /usr/bin/php ]]; then
ln -s /usr/bin/php /usr/local/bin/php
fi
fi
# Install NEMS Email Notifications Plugins
cp -f /root/nems/nems-migrator/data/1.5/nagios/plugins/nems_sendmail_host /usr/local/nagios/libexec/
cp -f /root/nems/nems-migrator/data/1.5/nagios/plugins/nems_sendmail_service /usr/local/nagios/libexec/
# Install notify-by-pushover
cp -f /root/nems/nems-migrator/data/1.4/submodules/barryo/nagios-plugins/notify-by-pushover.php /usr/local/nagios/libexec/
/bin/sed -i -- 's,Nagios Alert,NEMS Alert,g' /usr/local/nagios/libexec/notify-by-pushover.php
# Grab the Migrator plugins
cp -f /root/nems/nems-migrator/data/1.5/nagios/plugins/* /usr/local/nagios/libexec/
# Install notify-by-telegram
#MOVE THIS
cp -f /root/nems/nems-migrator/data/1.4/nagios/plugins/telegram_nems.lua /usr/local/bin/
chmod +x /usr/local/bin/telegram_nems.lua
# Install various plugins
cp -f /root/nems/nems-migrator/data/1.4/nagios/plugins/check_mikrotik_switch /usr/local/nagios/libexec/
cp -f /root/nems/nems-migrator/data/1.4/nagios/plugins/check_minecraft /usr/local/nagios/libexec/
cp -f /root/nems/nems-migrator/data/1.4/nagios/plugins/check_rpi_temperature /usr/local/nagios/libexec/
@@ -68,7 +68,7 @@ ln -sf /usr/local/share/nems/nems-scripts/upgrade.sh /usr/local/bin/nems-upgrade
# Enable NEMS MOTD
echo > /etc/motd
cp /root/nems/nems-migrator/data/nems/motd.tcl /etc/
cp /root/nems/nems-migrator/data/1.5/nems/motd.tcl /etc/
chmod 755 /etc/motd.tcl
if ! grep -q "/etc/motd.tcl" /etc/profile; then
echo "/etc/motd.tcl" >> /etc/profile
@@ -83,8 +83,10 @@ ln -s /var/www/html/share/nagios/ /usr/local/nagios/share
# Our Apache conf requires htpasswd exist in order to load.
# Prevent misleading errors before nems-init by creating an empty file.
touch /var/www/htpasswd
chown www-data:www-data /var/www/htpasswd
if [[ ! -e /var/www/htpasswd ]]; then
touch /var/www/htpasswd
chown www-data:www-data /var/www/htpasswd
fi
# Generate certificates
nems-cert

0 comments on commit f2e4bf5

Please sign in to comment.