]> git.phdru.name Git - ansible.git/blob - playbooks/roles/adjtimex/tasks/main.yml
Fix(adjtimex): Call `adjtimex` without `-h`
[ansible.git] / playbooks / roles / adjtimex / tasks / main.yml
1 - name: Install adjtimex and ntpdate-debian
2   become: true
3   apt:
4     autoclean: yes
5     autoremove: yes
6     cache_valid_time: 3600
7     install_recommends: no
8     name: ['adjtimex', 'ntpdate']
9     state: latest
10     update_cache: yes
11   when: ansible_facts.os_family == 'Debian'
12
13 - name: Install adjtimex and ntpdate
14   become: true
15   dnf:
16     name: ['adjtimex', 'ntpdate']
17     state: latest
18     update_cache: yes
19   when: ansible_facts.os_family == 'RedHat'
20
21 - name: Copy the script adjtimex.sh
22   become: true
23   template:
24     src: adjtimex.sh
25     dest: /usr/local/sbin/adjtimex.sh
26     owner: root
27     group: root
28     mode: 0750
29
30 - name: Configure adjtimex weekly run
31   become: true
32   copy:
33     src: adjtimex
34     dest: /etc/cron.weekly
35     owner: root
36     group: root
37     mode: '0700'