1
1
mirror of https://github.com/namibia/openvpn-install.git synced 2024-06-11 23:42:20 +00:00

Drop CentOS 6 support

This commit is contained in:
angristan 2018-09-16 01:26:30 +02:00
parent f057e0aa5f
commit 62380c512b
2 changed files with 16 additions and 10 deletions

View File

@ -66,7 +66,6 @@ The script is made to work on these OS and architectures :
- **Fedora 25** (amd64) - **Fedora 25** (amd64)
- **Fedora 26** (amd64) - **Fedora 26** (amd64)
- **Fedora 27** (amd64) - **Fedora 27** (amd64)
- **CentOS 6** (i386, amd64)
- **CentOS 7** (i386, amd64, arm64) - **CentOS 7** (i386, amd64, arm64)
- **Arch Linux** (i686, amd64, arm64) - **Arch Linux** (i686, amd64, arm64)

View File

@ -16,12 +16,6 @@ if [[ ! -e /dev/net/tun ]]; then
exit 2 exit 2
fi fi
# Check if CentOS 5
if grep -qs "CentOS release 5" "/etc/redhat-release"; then
echo "CentOS 5 is too old and not supported"
exit 3
fi
if [[ -e /etc/debian_version ]]; then if [[ -e /etc/debian_version ]]; then
OS="debian" OS="debian"
# Getting the version number, to verify that a recent version of OpenVPN is available # Getting the version number, to verify that a recent version of OpenVPN is available
@ -36,10 +30,10 @@ if [[ -e /etc/debian_version ]]; then
echo "then you can continue, a recent version of OpenVPN is available on these." echo "then you can continue, a recent version of OpenVPN is available on these."
echo "Keep in mind they are not supported, though." echo "Keep in mind they are not supported, though."
while [[ $CONTINUE != "y" && $CONTINUE != "n" ]]; do while [[ $CONTINUE != "y" && $CONTINUE != "n" ]]; do
read -rp "Continue ? [y/n]: " -e CONTINUE read -rp "Continue? [y/n]: " -e CONTINUE
done done
if [[ "$CONTINUE" = "n" ]]; then if [[ "$CONTINUE" = "n" ]]; then
echo "Ok, bye !" echo "Ok, bye!"
exit 4 exit 4
fi fi
fi fi
@ -47,7 +41,20 @@ elif [[ -e /etc/fedora-release ]]; then
OS=fedora OS=fedora
IPTABLES='/etc/iptables/iptables.rules' IPTABLES='/etc/iptables/iptables.rules'
SYSCTL='/etc/sysctl.d/openvpn.conf' SYSCTL='/etc/sysctl.d/openvpn.conf'
elif [[ -e /etc/centos-release || -e /etc/redhat-release || -e /etc/system-release ]]; then elif [[ -e /etc/centos-release ]]; then
if ! grep -qs "^CentOS Linux release 7" /etc/centos-release; then
echo "Your version of CentOS is not supported."
echo "The script only support CentOS 7."
echo ""
unset CONTINUE
while [[ $CONTINUE != "y" && $CONTINUE != "n" ]]; do
read -rp "Continue anyway? [y/n]: " -e CONTINUE
done
if [[ "$CONTINUE" = "n" ]]; then
echo "Ok, bye!"
exit 5
fi
fi
OS=centos OS=centos
IPTABLES='/etc/iptables/iptables.rules' IPTABLES='/etc/iptables/iptables.rules'
SYSCTL='/etc/sysctl.conf' SYSCTL='/etc/sysctl.conf'