Forge Home


Module to install and configure the chrony NTP service


56,998 latest version

4.6 quality score

We run a couple of automated
scans to help you access a
module's quality. Each module is
given a score based on how well
the author has formatted their
code and documentation and
modules are also checked for
malware using VirusTotal.

Please note, the information below
is for guidance only and neither of
these methods should be considered
an endorsement by Puppet.

Version information

  • 1.0.2 (latest)
  • 1.0.1
  • 1.0.0
released Mar 24th 2018
This version is compatible with:
  • , , ,

Start using this module

  • r10k or Code Manager
  • Bolt
  • Manual installation
  • Direct download

Add this module to your Puppetfile:

mod 'drzewiec-chrony', '1.0.2'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add drzewiec-chrony
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install drzewiec-chrony --version 1.0.2

Direct download is not typically how you would use a Puppet module to manage your infrastructure, but you may want to download the module in order to inspect the code.



drzewiec/chrony — version 1.0.2 Mar 24th 2018


Table of Contents

  1. Description
  2. Setup - The basics of getting started with chrony
  3. Usage - Configuration options and additional functionality
  4. Reference - An under-the-hood peek at what the module is doing and how
  5. Limitations - OS compatibility, etc.
  6. Development - Guide for contributing to the module


Module to install, configure, and manage the chrony service for Linux. Tested on Puppet 4.9 and 4.10, should work with older 4.x versions as well.


Beginning with chrony

Simply include the module to install chrony with all its defaults:

include chrony


To specify a different pool address (rather than the default format):

class { 'chrony':
  pool_address => '',

To specify a list of servers rather than a pool:

class { 'chrony':
  pool_use => false,
  servers => ['','','',''],

To allow clients to query your system for NTP (blocked by default):

class { 'chrony':
  client_allow => true,
  client_sources => [



This is the main class, and the only one that should be used. It calls the other classes in turn to install and configure chrony.


All parameters optional unless otherwise specified.

bindaddress: String, a specific address to listen for NTP requests.
client_allow: Boolean, sets whether or not to allow clients to connect.
client_sources: Array[String], a list of hostnames or IP networks allowed to connect. Required if client_allow is set to true.
config: String, specifies the location of the config file.
config_file_mode: String, specifies the access mode to set on the config file.
driftfile: String, specifies the location for the driftfile.
keyfile: String, specifies path to the keyfile used to authenticate access to chrony.
package_ensure: String, sets the "ensure" parameter on the package resource for chrony.
package_manage: Boolean, sets whether or not Puppet will manage the chrony package.
package_name: String, specifies the name of the chrony package.
pool_use: Boolean, sets whether or not to use a "pool" directive in chrony.conf.
pool_address: String, the address of the NTP pool to use.
pool_maxservers: Integer, the number of sources to pull from the pool.
pool_iburst: Boolean, specifies whether or not to set the iburst on the pool.
servers: Array[String], specifies the list of servers to sync time from. Required if pool_use is set to false.
service_enable: Boolean, whether to enable the chrony service to run at startup.
service_ensure: String, sets the "ensure" parameter on the service resource for chrony.
service_manage: Boolean, whether or not Puppet should manage the chrony service.
service_name: String, the name of the chrony service.


Installs the chrony package.


Builds chrony.conf based on the parameters passed into the base class.


Manages the chrony service.


Tested on Puppet 4.9 and 4.10, and the following Linux releases:

CentOS 6.9, 7.3
RHEL 7.3 Debian 7.11, 8.7
Ubuntu 12.04, 14.04, 16.04

Other Puppet 4.x versions should work, as nothing fancy is going on in the code here. Other Linux distros and versions may work, but no guarantees.