Commit 2b3c1fa4 authored by Valentino Lauciani's avatar Valentino Lauciani
Browse files

Update

parent 7a9443b4
......@@ -121,13 +121,11 @@ configure_nginx()
configure_iptables()
{
echo_date "Configuring \"iptables\":"
echo " check installation:"
echo "Check installation:"
dpkg-query -W -f='${Status} ${Version}\n' iptables
RETURNED_VAL=${?}
echo ""
if (( ${RETURNED_VAL} == 0 )) && [ -d ${GITBASEDIRCURREPO}/cnt.rm.ingv.it/root/etc/firewall/ ]; then
echo_date "Configuring \"iptables\":"
mkdir /etc/firewall
cd /etc/firewall
ln -s ${GITBASEDIRCURREPO}/cnt.rm.ingv.it/root/etc/firewall/firewall.openall.sh
......@@ -137,7 +135,8 @@ configure_iptables()
ln -s ${GITBASEDIRCURREPO}/cnt.rm.ingv.it/root/etc/init.d/iptables
/etc/init.d/iptables start
echo_date "Done"
else
echo "Error configuring..."
fi
echo_date "Done"
echo ""
......@@ -149,7 +148,6 @@ configure_fail2ban()
echo " check installation:"
dpkg-query -W -f='${Status} ${Version}\n' fail2ban
RETURNED_VAL=${?}
echo ""
if (( ${RETURNED_VAL} == 0 )) && [ -d ${GITBASEDIRCURREPO}/cnt.rm.ingv.it/root/etc/fail2ban/ ]; then
service fail2ban stop
......@@ -190,6 +188,8 @@ configure_fail2ban()
fi
service fail2ban start
else
echo "Error configuring..."
fi
echo_date "Done"
echo ""
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment