diff --git a/roles/chronyd/handlers/main.yml b/roles/chronyd/handlers/main.yml index 4a12e18..c6b9394 100644 --- a/roles/chronyd/handlers/main.yml +++ b/roles/chronyd/handlers/main.yml @@ -1,6 +1,6 @@ --- - name: Restart chronyd systemd: - name: chronyd.service + name: chrony.service state: restarted ... diff --git a/roles/chronyd/tasks/main.yml b/roles/chronyd/tasks/main.yml index 9910415..ee0bafc 100644 --- a/roles/chronyd/tasks/main.yml +++ b/roles/chronyd/tasks/main.yml @@ -1,4 +1,12 @@ --- +- name: Uninstall ntp and sntp + apt: + name: + - sntp + - ntp + - systemd-timesyncd + state: absent + - name: Install chronyd apt: name: chrony @@ -18,7 +26,7 @@ - name: Enable and start chronyd systemd: - name: chronyd.service + name: chrony.service enabled: true state: started ...