2014-07-11 16:25:39 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
. /lib/functions/service.sh
|
|
|
|
|
|
|
|
ifname_to_dev () {
|
2016-12-08 16:44:29 +00:00
|
|
|
ifstatus client "$1"|jsonfilter -e "@.device"
|
2014-07-11 16:25:39 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
case "$ACTION" in
|
|
|
|
ifup)
|
2015-04-23 16:18:13 +00:00
|
|
|
DEVICE="$(ifname_to_dev "$INTERFACE")"
|
2014-07-11 16:25:39 +00:00
|
|
|
|
2016-12-08 16:44:29 +00:00
|
|
|
[ "$DEVICE" != "$(cat /lib/gluon/respondd/client.dev 2>/dev/null)" ] ||
|
|
|
|
/etc/init.d/gluon-respondd restart_if_running &
|
2014-07-11 16:25:39 +00:00
|
|
|
;;
|
|
|
|
esac
|