Skip to content
This repository has been archived by the owner on Apr 15, 2019. It is now read-only.

Implement NTP and NTPDate Cron job #19

Closed
Isabello opened this issue Jun 22, 2017 · 2 comments
Closed

Implement NTP and NTPDate Cron job #19

Isabello opened this issue Jun 22, 2017 · 2 comments

Comments

@Isabello
Copy link
Contributor

In order to maintain time against the Host OS which can be untrustworthy, we should implement ntp and configure ntpdate on a cronjob to resolve potential time drift issues.

@Removed-5an
Copy link
Contributor

I have reviewed this suggestion and the idea has its merits but is impractical.

NTP needs to run as root and the container needs to run in privileged mode for it to be able to modify system time. Privileged mode exposes you to all sorts of problems and makes it lot more possible to compromise the host if the container was ever compromised.

A more viable solution is to run NTP on the docker host and mount the host time in the container:

-v /etc/localtime:/etc/localtime:ro

@Isabello
Copy link
Contributor Author

Ok no problem.

Isabello pushed a commit that referenced this issue Jun 23, 2017
Xenial and mount Host time in containers

Closes #19
Closes #20
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants