Debian based container that setups the system date based on an ntp.conf file.
110
This debian based container uses the ntp package to setup the system date based on the /etc/ntpsec/ntp.conf file. The setup is performed when the container starts. However, any write action to the /etc/ntpsec/ntp.conf file after the startup setup will re-trigger the system date update.
In order to be able to setup the system date, the container needs the --privileged flag.
docker run --detach --name ntp -v ~/ntp:/etc/ntpsec --privileged --restart=unless-stopped lecvalg/ntp:0.0.2
version: "3.9"
services:
ntp:
image: lecvalg/ntp:0.0.2
container_name: ntp
volumes:
- "~/ntp:/etc/ntpsec"
privileged: true
restart: unless-stopped
None.
/etc/ntpsec/ntp.conf file exists, and if not creates it./etc/ntpsec/ntp.conf file is not empty, and if it is fills it whith default content.First release.
/etc/ntpsec/ntp.conf file will prevent the container from working properly. Before running it, make sure the container /etc/ntpsec folder is bind mounted to a folder that contains a non-empty ntp.conf. Here is an example of a minimalistic ntp.conf file:server pool.ntp.org
Content type
Image
Digest
sha256:9345ecc1d…
Size
73.3 MB
Last updated
over 2 years ago
docker pull lecvalg/ntp:0.0.2