Merge "Disable firewall on rhel-based distros only"

This commit is contained in:
Jenkins 2015-07-28 09:37:07 +00:00 committed by Gerrit Code Review
commit 0fe6d2f8c8
3 changed files with 32 additions and 11 deletions

View File

@ -6,6 +6,13 @@ fi
set -eu
set -o pipefail
if which systemctl; then
systemctl disable firewalld
fi
case "${DISTRO_NAME}" in
fedora | centos | rhel )
if which systemctl; then
systemctl disable firewalld
fi
;;
* )
echo "Unknown distro: $DISTRO_NAME. Skipping."
;;
esac

View File

@ -10,7 +10,14 @@ if [ "$DISTRO_NAME" = "fedora" ]; then
install-packages iptables-services
fi
if which service; then
service ip6tables save
chkconfig ip6tables off
fi
case "${DISTRO_NAME}" in
fedora | centos | rhel )
if which service; then
service ip6tables save
chkconfig ip6tables off
fi
;;
* )
echo "Unknown distro: $DISTRO_NAME. Skipping."
;;
esac

View File

@ -10,7 +10,14 @@ if [ "$DISTRO_NAME" = "fedora" ]; then
install-packages iptables-services
fi
if which service; then
service iptables save
chkconfig iptables off
fi
case "${DISTRO_NAME}" in
fedora | centos | rhel )
if which service; then
service iptables save
chkconfig iptables off
fi
;;
* )
echo "Unknown distro: $DISTRO_NAME. Skipping."
;;
esac