aboutsummaryrefslogtreecommitdiffstats
path: root/50-ntpdate
blob: 4e7d89d6eed057152fbf1c6bd1080bd3e7d12826 (about) (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh

case "${reason}" in
	BOUND|REBIND|REBOOT|RENEW|TIMEOUT|STATIC)
		# sync time as soon as connection is up
		# this reads nameserver from /etc/ntp.conf
		ntpd --quit --panicgate
		# alternatively use ntpdate and give hostname
		#ntpdate -u pool.ntp.org
		;;
	PREINIT|EXPIRE|INFORM|FAIL|IPV4LL|NAK|NOCARRIER|RELEASE|STOP)
		# do nothing here...
		;;
esac