From e8074a485dbb0081b8dd37805cc245b2b0086b6d Mon Sep 17 00:00:00 2001 From: John E <44390932+jmeubank@users.noreply.github.com> Date: Sat, 25 Apr 2020 17:40:36 -0700 Subject: [PATCH] Fix easy-rsa old version removal The removal of an old version of easy-rsa should only happen if OpenVPN is being installed for the first time. --- openvpn-install.sh | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/openvpn-install.sh b/openvpn-install.sh index 02ef027..549671e 100755 --- a/openvpn-install.sh +++ b/openvpn-install.sh @@ -662,6 +662,7 @@ function installOpenVPN () { # Install required dependencies and upgrade the system pacman --needed --noconfirm -Syu openvpn iptables openssl wget ca-certificates curl fi + # An old version of easy-rsa was available by default in some openvpn packages if [[ -d /etc/openvpn/easy-rsa/ ]]; then rm -rf /etc/openvpn/easy-rsa/ fi @@ -674,11 +675,6 @@ function installOpenVPN () { NOGROUP=nobody fi - # An old version of easy-rsa was available by default in some openvpn packages - if [[ -d /etc/openvpn/easy-rsa/ ]]; then - rm -rf /etc/openvpn/easy-rsa/ - fi - # Install the latest version of easy-rsa from source, if not already # installed. if [[ ! -d /etc/openvpn/easy-rsa/ ]]; then