diff options
Diffstat (limited to 'meta-networking/recipes-support/ntp/files/ntpdate')
-rwxr-xr-x | meta-networking/recipes-support/ntp/files/ntpdate | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/meta-networking/recipes-support/ntp/files/ntpdate b/meta-networking/recipes-support/ntp/files/ntpdate index 784b029ad..ab0551c5a 100755 --- a/meta-networking/recipes-support/ntp/files/ntpdate +++ b/meta-networking/recipes-support/ntp/files/ntpdate | |||
@@ -6,11 +6,16 @@ test -x /usr/bin/ntpdate || exit 0 | |||
6 | 6 | ||
7 | if test -f /etc/default/ntpdate ; then | 7 | if test -f /etc/default/ntpdate ; then |
8 | . /etc/default/ntpdate | 8 | . /etc/default/ntpdate |
9 | else | ||
10 | NTPSERVERS="pool.ntp.org" | ||
11 | fi | 9 | fi |
12 | 10 | ||
13 | test -n "$NTPSERVERS" || exit 0 | 11 | if [ "$NTPSERVERS" = "" ] ; then |
12 | if [ "$METHOD" = "" -a "$1" != "silent" ] ; then | ||
13 | echo "Please set NTPSERVERS in /etc/default/ntpdate" | ||
14 | exit 1 | ||
15 | else | ||
16 | exit 0 | ||
17 | fi | ||
18 | fi | ||
14 | 19 | ||
15 | # This is a heuristic: The idea is that if a static interface is brought | 20 | # This is a heuristic: The idea is that if a static interface is brought |
16 | # up, that is a major event, and we can put in some extra effort to fix | 21 | # up, that is a major event, and we can put in some extra effort to fix |