From a7204cedbd260be9b55321c7781b89b3f3f4dbc4 Mon Sep 17 00:00:00 2001 From: Theodotos Andreou Date: Fri, 28 Apr 2017 10:24:11 +0300 Subject: [PATCH] Repurposing the cowops/debian-ntp Ansible role --- README.md | 9 +++++---- defaults/main.yml | 2 +- templates/ntp.conf.j2 | 5 +---- 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 20a53d5..635f9bc 100644 --- a/README.md +++ b/README.md @@ -6,13 +6,14 @@ Network Time Protocol Requirements ------------ -This role requires a debian compliant system such as ubuntu. +This Ansible role requires a debian compliant system such as ubuntu. This is a +simplified version of cowops/debian-ntp with just one internal ntp server. Role Variables -------------- ntp: - server: fr.pool.ntp.org + server: ntp.example.com Dependencies ------------ @@ -24,13 +25,13 @@ Example Playbook - hosts: servers roles: - - { role: cowops.debian-ntp, ntp.server: fr.pool.ntp.org } + - { role: theodotos.debian-ntp, ntp.server: ntp.example.com } Tasks ----- - Install [ntp](http://www.ntp.org/) - - Setup with [french ntp pool](http://www.pool.ntp.org/fr/) + - Setup with internal ntp pool License ------- diff --git a/defaults/main.yml b/defaults/main.yml index da2c5ec..6e8c96b 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -1,2 +1,2 @@ ntp: - server: fr.pool.ntp.org \ No newline at end of file + server: gr.pool.ntp.org diff --git a/templates/ntp.conf.j2 b/templates/ntp.conf.j2 index 5286c1b..66ecd01 100644 --- a/templates/ntp.conf.j2 +++ b/templates/ntp.conf.j2 @@ -18,10 +18,7 @@ filegen clockstats file clockstats type day enable # pool.ntp.org maps to about 1000 low-stratum NTP servers. Your server will # pick a different set every time it starts up. Please consider joining the # pool: -server 0.{{ ntp.server }} -server 1.{{ ntp.server }} -server 2.{{ ntp.server }} -server 3.{{ ntp.server }} +server {{ ntp.server }} # Access control configuration; see /usr/share/doc/ntp-doc/html/accopt.html for