Add support for AlmaLinux 8

AlmaLinux OS is 1:1 binary compatible with RHEL and pre-Stream CentOS.

Since Rocky Linux support is added, Alma should be added to to the checkOS function too as otherwise installation on Alma will fail.
This commit is contained in:
James Lee 2021-08-23 16:02:49 +08:00 committed by GitHub
parent d03d8d4580
commit cef4cd95be
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,7 +1,7 @@
#!/bin/bash #!/bin/bash
# shellcheck disable=SC1091,SC2164,SC2034,SC1072,SC1073,SC1009 # shellcheck disable=SC1091,SC2164,SC2034,SC1072,SC1073,SC1009
# Secure OpenVPN server installer for Debian, Ubuntu, CentOS, Amazon Linux 2, Fedora, Oracle Linux 8, Arch Linux and Rocky Linux. # Secure OpenVPN server installer for Debian, Ubuntu, CentOS, Amazon Linux 2, Fedora, Oracle Linux 8, Arch Linux, Rocky Linux and AlmaLinux.
# https://github.com/angristan/openvpn-install # https://github.com/angristan/openvpn-install
function isRoot() { function isRoot() {
@ -55,7 +55,7 @@ function checkOS() {
if [[ $ID == "fedora" || $ID_LIKE == "fedora" ]]; then if [[ $ID == "fedora" || $ID_LIKE == "fedora" ]]; then
OS="fedora" OS="fedora"
fi fi
if [[ $ID == "centos" || $ID == "rocky" ]]; then if [[ $ID == "centos" || $ID == "rocky" || $ID == "almalinux" ]]; then
OS="centos" OS="centos"
if [[ ! $VERSION_ID =~ (7|8) ]]; then if [[ ! $VERSION_ID =~ (7|8) ]]; then
echo "⚠️ Your version of CentOS is not supported." echo "⚠️ Your version of CentOS is not supported."