diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-05 18:43:21 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-05 18:43:21 +0000 |
commit | deb490e3727e8ab8c24e3fecbd91c8c7882bde3a (patch) | |
tree | 7d1bdaf4c2a0c63730410c2e0649369d3d5843f8 /debian/chrony.dhcp | |
parent | Adding upstream version 3.4. (diff) | |
download | chrony-deb490e3727e8ab8c24e3fecbd91c8c7882bde3a.tar.xz chrony-deb490e3727e8ab8c24e3fecbd91c8c7882bde3a.zip |
Adding debian version 3.4-4+deb10u2.debian/3.4-4+deb10u2debian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | debian/chrony.dhcp | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/debian/chrony.dhcp b/debian/chrony.dhcp new file mode 100644 index 0000000..690f3ab --- /dev/null +++ b/debian/chrony.dhcp @@ -0,0 +1,25 @@ +SERVERFILE=/var/lib/dhcp/chrony.servers.$interface + +chrony_config() { + rm -f $SERVERFILE + for server in $new_ntp_servers; do + echo "$server iburst" >> $SERVERFILE + done + /usr/lib/chrony/chrony-helper update-daemon || : +} + +chrony_restore() { + if [ -f $SERVERFILE ]; then + rm -f $SERVERFILE + /usr/lib/chrony/chrony-helper update-daemon || : + fi +} + +case $reason in + BOUND|RENEW|REBIND|REBOOT) + chrony_config + ;; + EXPIRE|FAIL|RELEASE|STOP) + chrony_restore + ;; +esac |