Skip to content
Permalink
Browse files

Create needed var folder

  • Loading branch information...
NEMS Linux
NEMS Linux committed Feb 25, 2019
1 parent cafe8f9 commit a15e86b981b5dc1ce24e7485f6f971d22c40e0a3
Showing with 12 additions and 0 deletions.
  1. +6 −0 build/050-nagios
  2. +6 −0 build/180-adagios
@@ -57,5 +57,11 @@ apt install -y nagios-nrpe-plugin nagios-nrpe-server nagios-images
# Set the nagios user shell
usermod -s /bin/bash nagios

# Add var folder (again, in case it got removed)
if [[ ! -e /var/lib/nagios/ ]]; then
mkdir /var/lib/nagios/
chown -R nagios:nagios /var/lib/nagios/
fi

# Reload daemon units in case Nagios was running while updated
systemctl daemon-reload
@@ -1,6 +1,12 @@
#!/bin/bash
echo $0 > /var/www/html/userfiles/nems-build.cur

# Add var folder if didn't get created in 050
if [[ ! -e /var/lib/nagios/ ]]; then
mkdir /var/lib/nagios/
chown -R nagios:nagios /var/lib/nagios/
fi

# Prepare sudo permissions
if ! grep -q "# Adagios" /etc/sudoers; then
echo '

0 comments on commit a15e86b

Please sign in to comment.
You can’t perform that action at this time.