This repository has been archived on 2024-07-30. You can view files and clone it, but cannot push or open issues or pull requests.
ansible-playbooks/timezone.yml

19 lines
505 B
YAML
Raw Normal View History

2024-05-22 23:43:48 -04:00
- name: Set timezone and configure timesyncd
hosts: "*"
become: yes
tasks:
- name: set timezone
shell: timedatectl set-timezone America/New_York
- name: Make sure timesyncd is stopped
systemd:
name: systemd-timesyncd.service
state: stopped
- name: Copy over the timesyncd config
template: src=../templates/timesyncd.conf dest=/etc/systemd/timesyncd.conf
- name: Make sure timesyncd is started
systemd:
name: systemd-timesyncd.service
state: started