116 lines
3.2 KiB
Plaintext
116 lines
3.2 KiB
Plaintext
################################################################################
|
|
### chrony.conf created by Puppet, manual changes will be overwritten ###
|
|
################################################################################
|
|
### original chrony.conf file can be found at https://3for.me/2t0an ###
|
|
################################################################################
|
|
|
|
<% if @fqdn == @cy_server_fqdn -%>
|
|
# This is a time server configuration file
|
|
# Use public servers from the pool.ntp.org project.
|
|
<% @cy_conf_servers.each do |this_server| -%>
|
|
pool <%= this_server %> iburst
|
|
<% end -%>
|
|
|
|
# Use NTP servers from DHCP.
|
|
sourcedir /run/chrony-dhcp
|
|
|
|
# Record the rate at which the system clock gains/losses time.
|
|
driftfile /var/lib/chrony/drift
|
|
|
|
# Allow the system clock to be stepped in the first three updates
|
|
# if its offset is larger than 1 second.
|
|
makestep 1.0 3
|
|
|
|
# Enable kernel synchronization of the real-time clock (RTC).
|
|
rtcsync
|
|
|
|
# Enable hardware timestamping on all interfaces that support it.
|
|
hwtimestamp *
|
|
|
|
# Increase the minimum number of selectable sources required to adjust
|
|
# the system clock.
|
|
minsources <%= @cy_min_sources %>
|
|
|
|
# Allow NTP client access from local network.
|
|
allow <%= @cy_client_allow %>
|
|
|
|
# Serve time even if not synchronized to a time source.
|
|
local stratum 10
|
|
|
|
# Require authentication (nts or key option) for all NTP sources.
|
|
#authselectmode require
|
|
|
|
# Specify file containing keys for NTP authentication.
|
|
keyfile /etc/chrony.keys
|
|
|
|
# Save NTS keys and cookies.
|
|
ntsdumpdir /var/lib/chrony
|
|
|
|
# Insert/delete leap seconds by slewing instead of stepping.
|
|
leapsecmode <%= @cy_leapsec_mode %>
|
|
|
|
# Get TAI-UTC offset and leap seconds from the system tz database.
|
|
leapsectz <%= @cy_leapsectz %>
|
|
|
|
# Specify directory for log files.
|
|
logdir /var/log/chrony
|
|
|
|
# Select which information is logged.
|
|
log <%= @cy_loginfo %>
|
|
|
|
<% end %>
|
|
|
|
|
|
<% if @fqdn != @cy_server_fqdn -%>
|
|
# This is a time client configuration file
|
|
server <%= @cy_server_fqdn %> iburst
|
|
|
|
# Use NTP servers from DHCP.
|
|
sourcedir /run/chrony-dhcp
|
|
|
|
# Record the rate at which the system clock gains/losses time.
|
|
driftfile /var/lib/chrony/drift
|
|
|
|
# Allow the system clock to be stepped in the first three updates
|
|
# if its offset is larger than 1 second.
|
|
makestep 1.0 3
|
|
|
|
# Enable kernel synchronization of the real-time clock (RTC).
|
|
rtcsync
|
|
|
|
# Enable hardware timestamping on all interfaces that support it.
|
|
hwtimestamp *
|
|
|
|
# Increase the minimum number of selectable sources required to adjust
|
|
# the system clock. Primarily for servers.
|
|
#minsources 2
|
|
|
|
# Allow NTP client access from local network.
|
|
#allow 192.168.0.0/16
|
|
|
|
# Serve time even if not synchronized to a time source.
|
|
#local stratum 10
|
|
|
|
# Require authentication (nts or key option) for all NTP sources.
|
|
#authselectmode require
|
|
|
|
# Specify file containing keys for NTP authentication.
|
|
keyfile /etc/chrony.keys
|
|
|
|
# Save NTS keys and cookies.
|
|
ntsdumpdir /var/lib/chrony
|
|
|
|
# Insert/delete leap seconds by slewing instead of stepping.
|
|
leapsecmode <%= @cy_leapsec_mode %>
|
|
|
|
# Get TAI-UTC offset and leap seconds from the system tz database.
|
|
leapsectz <%= @cy_leapsectz %>
|
|
|
|
# Specify directory for log files.
|
|
logdir /var/log/chrony
|
|
|
|
# Select which information is logged.
|
|
log <%= @cy_loginfo %>
|
|
|
|
<% end %>
|