1
0
mirror of synced 2024-11-21 20:46:10 +03:00

Fix for Raspberry Pi

- Raspberry Pis (ARM-based) may take some time on boot to initialize
  network interfaces such as Wi-Fi. Increasing the service restart
  delay in rc.local from 15 seconds to 60 seconds helps ensure that
  the VPN is enabled on these network interfaces.
This commit is contained in:
hwdsl2 2023-05-19 21:28:19 -05:00
parent d343401cca
commit 22838b714c

View File

@ -672,10 +672,14 @@ EOF
else
echo '#!/bin/sh' > /etc/rc.local
fi
cat >> /etc/rc.local <<'EOF'
rc_delay=15
if uname -m | grep -qi '^arm'; then
rc_delay=60
fi
cat >> /etc/rc.local <<EOF
# Added by hwdsl2 VPN script
(sleep 15
(sleep $rc_delay
service ipsec restart
service xl2tpd restart
echo 1 > /proc/sys/net/ipv4/ip_forward)&