nixpkgs-suyu/configuration/etc/dhclient-exit-hooks
Eelco Dolstra f037f6fbd4 * Emit ip-up / ip-down events when we get or lose a DHCP lease.
* ntpd: start on ip-up, not when the network interfaces are up,
  otherwise it will fail because it can't find any servers right
  away.

svn path=/nixos/trunk/; revision=7461
2006-12-22 17:28:25 +00:00

10 lines
267 B
Text

echo "$reason" >> /tmp/dhcp-exit
echo "$exit_status" >> /tmp/dhcp-exit
if test "$reason" = BOUND -o "$reason" = REBOOT; then
@upstart@/sbin/initctl emit ip-up
fi
if test "$reason" = EXPIRE -o "$reason" = RELEASE; then
@upstart@/sbin/initctl emit ip-down
fi