refactor: move shared Ansible tasks to ansible/tasks/

This commit is contained in:
rblundon committed 2026-02-25 20:51:02 -06:00
1 parent 86708542c9
commit 7187dc8280
3 files changed

No files matched your search

+10
View File
@@ -0,0 +1,10 @@
---
- name: Add DHCP entry for {{ inventory_hostname }}
delegate_to: "{{ dhcp_server }}"
become: true
ansible.builtin.lineinfile:
path: /etc/dnsmasq.d/hosts.conf
regexp: "# {{ inventory_hostname }}$"
line: "dhcp-host={{ host_mac_address | lower }},{{ host_ip_address }} # {{ inventory_hostname }}"
state: present
notify: Restart dnsmasq