diff --git a/README.md b/README.md index 0f7e9895..0d306a00 100644 --- a/README.md +++ b/README.md @@ -558,6 +558,16 @@ Whether to enable tos options. Default value: `false`. +#### `tos_maxclock` + +Optional. + +Data type: Integer[1]. + +Specifies the maxclock tos option. + +Default value: 6. + #### `tos_minclock` Optional. diff --git a/data/common.yaml b/data/common.yaml index 47bcb51a..50921822 100644 --- a/data/common.yaml +++ b/data/common.yaml @@ -54,6 +54,7 @@ ntp::tinker: ~ ntp::tos_ceiling: 15 ntp::tos_cohort: 0 ntp::tos_floor: 1 +ntp::tos_maxclock: 6 ntp::tos_minclock: 3 ntp::tos_minsane: 1 ntp::tos: false diff --git a/manifests/init.pp b/manifests/init.pp index 6f10e7ff..53c91b57 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -108,6 +108,7 @@ Optional[String] $step_tickers_template, Optional[Boolean] $tinker, Boolean $tos, + Optional[Integer[1]] $tos_maxclock, Optional[Integer[1]] $tos_minclock, Optional[Integer[1]] $tos_minsane, Optional[Integer[1]] $tos_floor, diff --git a/templates/ntp.conf.epp b/templates/ntp.conf.epp index a9f0ac04..05a612b4 100644 --- a/templates/ntp.conf.epp +++ b/templates/ntp.conf.epp @@ -130,7 +130,7 @@ leapfile <%= $ntp::leapfile %> <% } -%> <%# -%> <% if $ntp::tos {-%> -tos <% if $ntp::tos_minclock {-%> minclock <%= $ntp::tos_minclock %><% } %> <% if $ntp::tos_minsane {-%> minsane <%= $ntp::tos_minsane %> <% } %><% if $ntp::tos_floor {-%> floor <%= $ntp::tos_floor %><% } %> <% if $ntp::tos_ceiling {-%> ceiling <%= $ntp::tos_ceiling %><% } %> <% if $ntp::tos_cohort {-%> cohort <%= $ntp::tos_cohort %><% } %> +tos <% if $ntp::tos_minclock {-%> minclock <%= $ntp::tos_minclock %><% } %> <% if $ntp::tos_maxclock {-%> maxclock <%= $ntp::tos_maxclock %><% } %> <% if $ntp::tos_minsane {-%> minsane <%= $ntp::tos_minsane %><% } %> <% if $ntp::tos_floor {-%> floor <%= $ntp::tos_floor %><% } %> <% if $ntp::tos_ceiling {-%> ceiling <%= $ntp::tos_ceiling %><% } %> <% if $ntp::tos_cohort {-%> cohort <%= $ntp::tos_cohort %><% } %> <% } %> <%# -%> <% if $ntp::authprov {-%>