Skip to content

Commit

Permalink
Merge pull request #3 from CvX/ntp-fallback
Browse files Browse the repository at this point in the history
Fallback to pool.ntp.org if NTP isn't configured
  • Loading branch information
arunvelsriram authored Mar 13, 2017
2 parents 6bd0097 + 0436a20 commit c9940b5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docker-time-sync-agent/update-docker-time
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
# Created by ArunvelSriram on 26/12/16.
# Copyright © 2016 ArunvelSriram. All rights reserved.

/usr/local/bin/docker run --rm --privileged --pid=host walkerlee/nsenter -t 1 -m -u -i -n ntpd -d -q -n -p `cat /etc/ntp.conf | awk '{ print $2 }'`
/usr/local/bin/docker run --rm --privileged --pid=host walkerlee/nsenter -t 1 -m -u -i -n ntpd -d -q -n -p `if [[ -f /etc/ntp.conf ]]; then cat /etc/ntp.conf | awk '{ print $2 }'; else echo 'pool.ntp.org'; fi`

0 comments on commit c9940b5

Please sign in to comment.