mirror of
https://github.com/kiddin9/op-packages.git
synced 2026-11-03 12:13:56 +08:00
🎨 Sync 2026-06-03 02:25:48
This commit is contained in:
1 parent
3a1640ace3
commit
3ce5a14c9f
63 files changed
+15671
-6792
No files matched your search
@@ -0,0 +1,22 @@
|
||||
#!/bin/sh
|
||||
|
||||
[ "$ACTION" = "ifup" ] || exit 0
|
||||
[ "$INTERFACE" = "wan" ] || exit 0
|
||||
|
||||
WAN_PROTO="$(uci -q get network.wan.proto 2>/dev/null)"
|
||||
[ "$WAN_PROTO" = "pppoe" ] || exit 0
|
||||
|
||||
LOCK_FILE="/var/run/ssrplus-pppoe-hotplug.lock"
|
||||
|
||||
(
|
||||
if ! mkdir "$LOCK_FILE" 2>/dev/null; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
trap 'rmdir "$LOCK_FILE" 2>/dev/null' EXIT INT TERM
|
||||
|
||||
sleep 10
|
||||
/etc/init.d/shadowsocksr restart >/dev/null 2>&1
|
||||
) >/dev/null 2>&1 &
|
||||
|
||||
exit 0
|
||||
Reference in new issue
Block a user