Skip to content
Snippets Groups Projects
Commit 0667a461 authored by Chris Hines's avatar Chris Hines
Browse files

start ntpd by default

Former-commit-id: 264d1610
parent 18fd1faf
No related branches found
No related tags found
No related merge requests found
......@@ -3,7 +3,8 @@
with_items:
- ntp
- ntpdate
sudo: true
become: true
become_user: root
when: ansible_os_family == 'RedHat'
- name: "Installing ntp packages apt"
......@@ -11,12 +12,20 @@
with_items:
- ntp
- ntpdate
sudo: true
become: true
become_user: root
when: ansible_os_family == 'Debian'
- name: "ntp time sync"
shell: ntpdate -u {{ ntp_server }}
args:
creates: /etc/ntp.conf
sudo: true
become: true
become_user: root
notify: restart ntpd
- name: "enable ntp"
service: name=ntpd enabled=yes state=started
become: true
become_user: root
when: ansible_os_family == 'RedHat'
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment