summaryrefslogtreecommitdiff
path: root/multitech/recipes/ntp/ntp_4.2.6p3.bbappend
blob: c0e6dc43c7fe2991476d3e60b5f1e4b69e055bce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
PR .= ".corecdp1"

# create cron job and throw away output to avoid email attempts
pkg_postinst_ntpdate() {
if test "x$D" != "x"; then
        exit 1
else
        if ! grep -q -s ntpdate /var/cron/tabs/root; then
                echo "adding crontab"
                test -d /var/cron/tabs || mkdir -p /var/cron/tabs
                echo "30 * * * *    /usr/bin/ntpdate -b -s -u pool.ntp.org >/dev/null 2>&1" >> /var/cron/tabs/root
        fi
fi
}