mirror of
https://github.com/kiddin9/op-packages.git
synced 2026-11-08 13:14:12 +08:00
🤞 Sync 2026-10-29 22:46:41
This commit is contained in:
1 parent
ff521a5a6a
commit
8d20d896c0
78 files changed
+16387
-1210
No files matched your search
@@ -0,0 +1,9 @@
|
||||
# Start vnStat tracking for interfaces as they come up (modems, PPPoE and
|
||||
# VPNs often only get their device name at this point).
|
||||
[ "$ACTION" = ifup ] || exit 0
|
||||
[ "$INTERFACE" = loopback ] && exit 0
|
||||
[ -x /usr/libexec/netstat-vnstat-track ] || exit 0
|
||||
|
||||
dev="$DEVICE"
|
||||
[ -n "$dev" ] || dev="$(ubus call network.interface."$INTERFACE" status 2>/dev/null | jsonfilter -e '@.l3_device' 2>/dev/null)"
|
||||
[ -n "$dev" ] && /usr/libexec/netstat-vnstat-track "$dev"
|
||||
Reference in new issue
Block a user