summaryrefslogtreecommitdiff
path: root/data
diff options
context:
space:
mode:
authorDaniil Baturin <daniil@vyos.io>2026-08-14 14:04:48 +0100
committerGitHub <noreply@github.com>2026-08-14 14:04:48 +0100
commitc30f15ae89e9c67d065cc033131da44bd8b4d9c8 (patch)
treeeb5a638829f48855eea7bda3bc88dd19d951f8d7 /data
parent0775edcd1eaa668d789f0ee9d00da14f11e7c1dd (diff)
parentd3b48b76bd71fec1d09db6c72963de797f8ccb93 (diff)
downloadvyos-1x-c30f15ae89e9c67d065cc033131da44bd8b4d9c8.tar.gz
vyos-1x-c30f15ae89e9c67d065cc033131da44bd8b4d9c8.zip
Merge pull request #5371 from ruben-herold/T9159-ntp-source-address
ntp: T9159: add source-address option for client requests
Diffstat (limited to 'data')
-rw-r--r--data/templates/chrony/chrony.conf.j213
1 files changed, 13 insertions, 0 deletions
diff --git a/data/templates/chrony/chrony.conf.j2 b/data/templates/chrony/chrony.conf.j2
index 23b452f01..271c6de87 100644
--- a/data/templates/chrony/chrony.conf.j2
+++ b/data/templates/chrony/chrony.conf.j2
@@ -72,6 +72,19 @@ binddevice {{ interface }}
{% endif %}
{% endif %}
+{% if source_address is vyos_defined or source_interface is vyos_defined %}
+# Source used for outgoing NTP client requests, independent of whichever
+# interface the kernel's routing table selects for a given server
+{% if source_address is vyos_defined %}
+{% for address in source_address %}
+bindacqaddress {{ address }}
+{% endfor %}
+{% endif %}
+{% if source_interface is vyos_defined %}
+bindacqdevice {{ source_interface }}
+{% endif %}
+{% endif %}
+
{% if timestamp.interface is vyos_defined %}
# Enable hardware timestamping on the specified interfaces
{% for iface, iface_config in timestamp.interface.items() %}