summaryrefslogtreecommitdiffstats
path: root/roles/chrony/tasks/main.yml
diff options
context:
space:
mode:
authorMatt Woodson <mwoodson@redhat.com>2016-01-18 15:21:04 -0500
committerMatt Woodson <mwoodson@redhat.com>2016-01-18 15:21:04 -0500
commit9802775b6642d4257b4b2cd9a4e27a4a86bf01d8 (patch)
tree2210ac2067f89facccc218c45f4cd57fba36f359 /roles/chrony/tasks/main.yml
parent965c614859a0318c956b4a9ab312c7c856facaa1 (diff)
downloadopenshift-9802775b6642d4257b4b2cd9a4e27a4a86bf01d8.tar.gz
openshift-9802775b6642d4257b4b2cd9a4e27a4a86bf01d8.tar.bz2
openshift-9802775b6642d4257b4b2cd9a4e27a4a86bf01d8.tar.xz
openshift-9802775b6642d4257b4b2cd9a4e27a4a86bf01d8.zip
added chrony
Diffstat (limited to 'roles/chrony/tasks/main.yml')
-rw-r--r--roles/chrony/tasks/main.yml30
1 files changed, 30 insertions, 0 deletions
diff --git a/roles/chrony/tasks/main.yml b/roles/chrony/tasks/main.yml
new file mode 100644
index 000000000..fae6d8e4c
--- /dev/null
+++ b/roles/chrony/tasks/main.yml
@@ -0,0 +1,30 @@
+---
+- name: remove ntp package
+ yum:
+ name: ntp
+ state: absent
+
+- name: ensure chrony package is installed
+ yum:
+ name: chrony
+ state: installed
+
+- name: Install /etc/chrony.conf
+ template:
+ src: chrony.conf.j2
+ dest: /etc/chrony.conf
+ owner: root
+ group: root
+ mode: 0644
+ notify:
+ - Restart chronyd
+
+- name: enabled timedatectl set-ntp yes
+ timedatectl:
+ ntp: True
+
+- name:
+ service:
+ name: chronyd
+ state: started
+ enabled: yes