Skip to content

Commit

Permalink
Improve error message
Browse files Browse the repository at this point in the history
  • Loading branch information
Nyr committed Apr 23, 2024
1 parent b86d97d commit 1a484a6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions openvpn-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,9 @@ This version of Debian is too old and unsupported."
fi

if [[ "$os" == "centos" && "$os_version" -lt 9 ]]; then
echo "CentOS 9 or higher is required to use this installer.
This version of CentOS is too old and unsupported."
os_name=$(sed 's/ release.*//' /etc/almalinux-release /etc/rocky-release /etc/centos-release 2>/dev/null | head -1)
echo "$os_name 9 or higher is required to use this installer.
This version of $os_name is too old and unsupported."
exit
fi

Expand Down

0 comments on commit 1a484a6

Please sign in to comment.