Add cron to update pihole
This commit is contained in:
parent
4921c932d6
commit
f82cca1ece
2 changed files with 10 additions and 0 deletions
2
hosts
2
hosts
|
@ -4,9 +4,11 @@ dns:
|
||||||
dns_1:
|
dns_1:
|
||||||
ansible_host: 192.168.1.3
|
ansible_host: 192.168.1.3
|
||||||
sync_target: 192.168.1.4
|
sync_target: 192.168.1.4
|
||||||
|
update_weekday: 1
|
||||||
dns_2:
|
dns_2:
|
||||||
ansible_host: 192.168.1.4
|
ansible_host: 192.168.1.4
|
||||||
sync_target: 192.168.1.3
|
sync_target: 192.168.1.3
|
||||||
|
update_weekday: 2
|
||||||
proxy:
|
proxy:
|
||||||
hosts:
|
hosts:
|
||||||
proxy_1:
|
proxy_1:
|
||||||
|
|
|
@ -52,6 +52,14 @@
|
||||||
cmd: /tmp/basic-install.sh --unattended
|
cmd: /tmp/basic-install.sh --unattended
|
||||||
creates: /usr/local/bin/pihole
|
creates: /usr/local/bin/pihole
|
||||||
|
|
||||||
|
- name: Schedule upgrade
|
||||||
|
cron:
|
||||||
|
name: schedule upgrade
|
||||||
|
weekday: "{{ update_weekday }}"
|
||||||
|
hour: 3
|
||||||
|
minute: 0
|
||||||
|
job: /usr/local/bin/pihole -up
|
||||||
|
|
||||||
- name: Create gravity directory
|
- name: Create gravity directory
|
||||||
file:
|
file:
|
||||||
path: /etc/gravity-sync
|
path: /etc/gravity-sync
|
||||||
|
|
Loading…
Reference in a new issue