centos7_l2tp_ipsec_vpn_脚本.sh

centos7_l2tp_ipsec_vpn_脚本.sh

#!/bin/bash

# <UDF name="VPN_IPSEC_PSK" Label="IPsec Pre-Shared Key" />
# <UDF name="VPN_USER" Label="VPN Username" />
# <UDF name="VPN_PASSWORD" Label="VPN Password" />

if [ -f /etc/apt/sources.list ]; then
  url=vpnsetup
  apt-get -y update
  apt-get -y install wget
elif [ -f /etc/yum.conf ]; then
  url=vpnsetup-centos
  yum -y install wget
else
  echo "Your distribution is not supported by this StackScript"
  exit 1
fi

wget "https://git.io/$url" -O /tmp/vpn.sh && sh /tmp/vpn.sh && rm -f /tmp/vpn.sh

# Fix xl2tpd on CentOS 7 for Linode VMs, because kernel module
# l2tp_ppp is not available in the default Linode kernel
if grep -qs "release 7" /etc/redhat-release; then
  if [ -f /usr/lib/systemd/system/xl2tpd.service ]; then
    sed -i '/ExecStartPre/s/^/#/' /usr/lib/systemd/system/xl2tpd.service
    systemctl daemon-reload
    systemctl restart xl2tpd
  fi
fi
Teo

2条评论

very hairy guys 发布于13:12 - 2021年3月5日

Me encanta ese buen gusto del emplatado y el combinado de sabores Alanah Orbadiah Corwin

bursa escort 发布于06:26 - 2021年3月2日

We use cookies and tracking technologies to improve your browsing experience on our website. By browsing our website, you consent to our use of cookies and other tracking technologies. Eimile Ingram Leann

You must be logged in to post a comment