1 #####################################
2 ### someone's ansible provisioner ###
3 #####################################
4 # Part of: https://git.somenet.org/root/pub/somesible.git
5 # 2017-2024 by someone <someone@somenet.org>
8 - name: install dhcp-server
15 ignore_errors: "{{ignore_online_errors | bool}}"
18 - name: set interfaces to serve
20 name: /etc/default/isc-dhcp-server
21 regexp: '^INTERFACESv4='
22 line: 'INTERFACESv4="{{dhcpd_interfaces}}"'
25 - name: copy dhcpd.conf
28 dest: "/etc/dhcp/dhcpd.conf"
33 - "{{lookup('env','PWD')}}/host_files/{{inventory_hostname}}/{{role_name}}/dhcpd.conf"
34 - "{{lookup('env','PWD')}}/group_files/{{group_files_group}}/{{role_name}}/dhcpd.conf"
35 - "{{lookup('env','PWD')}}/group_files/all/{{role_name}}/dhcpd.conf"
36 - "default/dhcpd.conf"
37 notify: restart isc-dhcp-server.service
40 - name: enable and start isc-dhcp-server.service
41 include_role: name="base/systemd/enable-and-start"
43 service_name: isc-dhcp-server.service