shell/install/openvpn
2024-12-02 16:12:18 +08:00

32 lines
921 B
Bash
Executable File

#!/bin/bash
##makedesc: Install openvpn v2.6.3 (src)
source "$( dirname $(readlink -e -- "${BASH_SOURCE}"))/../helpers.sh" || exit 255
# https://openvpn.net/community-downloads/
# https://openvpn.net/community-resources/installing-openvpn/
[ "$1" ] && OVPNVER="$1" || OVPNVER='2.6.3'
title "Installing openvpn v${OVPNVER} (src)..."
require libssl-dev \
liblzo2-dev \
libpam0g-dev
mkdir -p "$HOME/install/"
download "https://swupdate.openvpn.org/community/releases/openvpn-${OVPNVER}.tar.gz" "$HOME/install/openvpn-${OVPNVER}.tar.gz" && \
unpack_targz "$HOME/install/openvpn-${OVPNVER}.tar.gz" "$HOME/install/" && \
cd "$HOME/install/openvpn-${OVPNVER}" && \
sudo ./configure && \
sudo make && \
sudo make install &&
apt_install network-manager-openvpn \
network-manager-openvpn-gnome
[ $? = 0 ] && {
echo
success "openvpn installed!"
openvpn --version
echo
}