diff --git a/handlers/main.yml b/handlers/main.yml index 4b186f4..1fe92a2 100644 --- a/handlers/main.yml +++ b/handlers/main.yml @@ -1,12 +1,14 @@ --- # handlers file for systemd-timesyncd - name: "restart systemd-timesyncd" + become: true service: name: systemd-timesyncd.service state: restarted listen: systemd-timesyncd configuration changed - name: "write adjtime" + become: true command: hwclock --systohc when: (ansible_virtualization_role == "host" or ansible_virtualization_role == "NA") and write_hwclock_on_change - listen: systemd-timesyncd configuration changed \ No newline at end of file + listen: systemd-timesyncd configuration changed