Infra/ansible/roles/pihole/tasks/main.yml
2022-04-15 15:51:58 +02:00

18 lines
402 B
YAML

- name: Check if PiHole is cloned
ansible.builtin.stat:
path: "/etc/pihole"
register: pihole_clone
- name: Gather PiHole
when: not pihole_clone.stat.exists
include_tasks: gather.yml
- name: Check if PiHole is installed
ansible.builtin.stat:
path: "/usr/local/bin/pihole"
register: pihole_bin
- name: Configure PiHole
when: pihole_bin.stat.exists
include_tasks: configure.yml