This commit is contained in:
Bob Mottram 2017-09-25 22:43:50 +01:00
parent fdaad4e96f
commit 874816cd05
1 changed files with 2 additions and 2 deletions

View File

@ -197,7 +197,7 @@ function create_user_vpn_key {
cp /usr/share/doc/openvpn/examples/sample-config-files/client.conf $user_vpn_cert_file cp /usr/share/doc/openvpn/examples/sample-config-files/client.conf $user_vpn_cert_file
sed -i "s|remote .*|remote $DEFAULT_DOMAIN_NAME 1194|g" $user_vpn_cert_file sed -i "s|remote .*|remote $DEFAULT_DOMAIN_NAME 1194|g" $user_vpn_cert_file
sed -i 's|;user nobody|user nobody|g' $user_vpn_cert_file sed -i 's|;user nobody|user nobody|g' $user_vpn_cert_file
sed -i 's|;group nogroup|group nogroup|g' $user_vpn_cert_file sed -i 's|;group nogroup|group nobody|g' $user_vpn_cert_file
sed -i 's|ca ca.crt|;ca ca.crt|g' $user_vpn_cert_file sed -i 's|ca ca.crt|;ca ca.crt|g' $user_vpn_cert_file
sed -i 's|cert client.crt|;cert client.crt|g' $user_vpn_cert_file sed -i 's|cert client.crt|;cert client.crt|g' $user_vpn_cert_file
@ -248,7 +248,7 @@ function install_vpn {
sed -i "s|;push \"redirect-gateway|push \"redirect-gateway|g" /etc/openvpn/server.conf sed -i "s|;push \"redirect-gateway|push \"redirect-gateway|g" /etc/openvpn/server.conf
sed -i 's|;push "dhcp-option|push "dhcp-option|g' /etc/openvpn/server.conf sed -i 's|;push "dhcp-option|push "dhcp-option|g' /etc/openvpn/server.conf
sed -i 's|;user nobody|user nobody|g' /etc/openvpn/server.conf sed -i 's|;user nobody|user nobody|g' /etc/openvpn/server.conf
sed -i 's|;group nogroup|group nogroup|g' /etc/openvpn/server.conf sed -i 's|;group nogroup|group nobody|g' /etc/openvpn/server.conf
echo 1 > /proc/sys/net/ipv4/ip_forward echo 1 > /proc/sys/net/ipv4/ip_forward
sed -i 's|# net.ipv4.ip_forward|net.ipv4.ip_forward|g' /etc/sysctl.conf sed -i 's|# net.ipv4.ip_forward|net.ipv4.ip_forward|g' /etc/sysctl.conf