You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
438 B
Plaintext

# create avahi state directory
mkdir -p /var/lib
[ add = "$ACTION" ] && {
[ -n "$INTERFACE" ] && {
[ "$DEVTYPE" = "bridge" ] && INTERFACE=${INTERFACE#br-}
AUTOIP_OPT=$(uci -q get network.${INTERFACE}.autoip)
[ "${AUTOIP_OPT}" = "yes" ] && {
avahi-autoipd -s -D ${DEVICENAME}
}
}
}
[ remove = "$ACTION" ] && {
[ -n "$INTERFACE" ] && {
# no use in checking the config, it is gone
avahi-autoipd -s -k ${DEVICENAME}
}
}