mirror of
https://github.com/Nyr/openvpn-install.git
synced 2024-11-23 13:36:08 +03:00
Merge pull request #849 from trivvz/patch-1
Increase priority of openvpn-forward.conf
This commit is contained in:
commit
4f737ac2f8
@ -326,12 +326,12 @@ crl-verify crl.pem" >> /etc/openvpn/server/server.conf
|
||||
echo "explicit-exit-notify" >> /etc/openvpn/server/server.conf
|
||||
fi
|
||||
# Enable net.ipv4.ip_forward for the system
|
||||
echo 'net.ipv4.ip_forward=1' > /etc/sysctl.d/30-openvpn-forward.conf
|
||||
echo 'net.ipv4.ip_forward=1' > /etc/sysctl.d/99-openvpn-forward.conf
|
||||
# Enable without waiting for a reboot or service restart
|
||||
echo 1 > /proc/sys/net/ipv4/ip_forward
|
||||
if [[ -n "$ip6" ]]; then
|
||||
# Enable net.ipv6.conf.all.forwarding for the system
|
||||
echo "net.ipv6.conf.all.forwarding=1" >> /etc/sysctl.d/30-openvpn-forward.conf
|
||||
echo "net.ipv6.conf.all.forwarding=1" >> /etc/sysctl.d/99-openvpn-forward.conf
|
||||
# Enable without waiting for a reboot or service restart
|
||||
echo 1 > /proc/sys/net/ipv6/conf/all/forwarding
|
||||
fi
|
||||
@ -537,7 +537,7 @@ else
|
||||
systemctl disable --now openvpn-server@server.service
|
||||
rm -rf /etc/openvpn/server
|
||||
rm -f /etc/systemd/system/openvpn-server@server.service.d/disable-limitnproc.conf
|
||||
rm -f /etc/sysctl.d/30-openvpn-forward.conf
|
||||
rm -f /etc/sysctl.d/99-openvpn-forward.conf
|
||||
if [[ "$os" = "debian" || "$os" = "ubuntu" ]]; then
|
||||
apt-get remove --purge -y openvpn
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user