fix: enable and start systemd-timesyncd in common time role
systemd-timesyncd was installed via common_packages but never enabled or started, causing NodeClockNotSynchronising alerts across all k3s nodes.
This commit is contained in:
@@ -9,3 +9,18 @@
|
||||
community.general.timezone:
|
||||
name: "{{ timezone }}"
|
||||
when: ansible_user_id == "root"
|
||||
|
||||
- name: Enable and start systemd-timesyncd
|
||||
ansible.builtin.systemd:
|
||||
name: systemd-timesyncd
|
||||
enabled: true
|
||||
state: started
|
||||
become: true
|
||||
when: ansible_user_id != "root"
|
||||
|
||||
- name: Enable and start systemd-timesyncd
|
||||
ansible.builtin.systemd:
|
||||
name: systemd-timesyncd
|
||||
enabled: true
|
||||
state: started
|
||||
when: ansible_user_id == "root"
|
||||
|
||||
Reference in New Issue
Block a user