ansible-edda/plays/services/roles/base/tasks/include/system/nameserver.yml

15 lines
485 B
YAML
Raw Normal View History

2022-12-10 21:39:04 +01:00
- name: "system : nameserver : fetch valkyrie's resolv.conf"
ansible.builtin.fetch:
src: "/etc/resolv.conf"
dest: "./files/base/system/nameserver/"
flat: true
when:
ansible_hostname == "valkyrie"
- name: "system : nameserver : copy valkyrie's resolv.conf to other hosts"
ansible.builtin.copy:
src: "../../../files/base/system/nameserver/resolv.conf"
dest: "/var/lib/{{ ansible_hostname }}/valkyrie-resolv.conf"
when:
ansible_hostname != "valkyrie"