Restructuring/renaming DNS, DHCP, TFTP and netboot installer.

Idea: The role 'dnsmasq' and a new role 'dns-dhcp-tftp' are
drop-in replacements and interchangeable. 'netboot-installer'
works indepently of the role chosen for DNS, DHCP and TFTP.
This commit is contained in:
Andreas B. Mundt 2021-04-09 10:31:16 +02:00 committed by Andreas B. Mundt
parent e55997a01c
commit ebcfd88ef4
10 changed files with 18 additions and 18 deletions
kerberox.yml
roles
dhcp-dns-dnsmasq/templates
dnsmasq
netboot-installer
defaults
handlers
tasks
sambox.yml

View file

@ -47,8 +47,8 @@
roles:
- up2date-debian
- two-interface-firewalld
- dhcp-dns-dnsmasq
- tftp-netboot-installer
- netboot-installer
- dnsmasq
- apt-cacher
- { role: krb5-kdc-ldap, when: not run_in_installer|default(false)|bool }
- { role: nfs-server, when: not run_in_installer|default(false)|bool }

View file

@ -1,3 +0,0 @@
interface={{ if_lan }}
dhcp-range={{ dhcp_range }}
dhcp-generate-names

View file

@ -9,8 +9,14 @@
- resolvconf
state: latest
- name: configure dnsmasq
- name: configure dnsmasq dhcp
template:
src: dnsmasq-dhcp.j2
dest: /etc/dnsmasq.d/dnsmasq-dhcp
notify: "restart dnsmasq"
- name: configure dnsmasq tftp
template:
src: dnsmasq-tftp-netboot-installer.j2
dest: /etc/dnsmasq.d/tftp-netboot-installer
notify: "restart dnsmasq"

View file

@ -0,0 +1,3 @@
interface={{ if_lan }}
dhcp-range={{ dhcp_start }},{{ dhcp_stop }},2h
dhcp-generate-names

View file

@ -17,14 +17,7 @@
src: /usr/share/doc/di-netboot-assistant/examples/preseed.cfg
dest: "{{ tftp_root }}/d-i/{{ di_dist }}"
force: no
- name: configure dnsmasq
template:
src: dnsmasq-tftp-netboot-installer.j2
dest: /etc/dnsmasq.d/tftp-netboot-installer
notify:
- restart dnsmasq
- rebuild di-netboot-assistant menu
remote_src: yes
- name: make the hostname resolvable from the LAN
replace:

View file

@ -18,8 +18,9 @@
## LAN IP address range:
ipaddr_lan: 192.168.0.10/24
dhcp_range: 192.168.0.50,192.168.0.99,2h
in_inventory: 192.168.0.[50:99]
dhcp_start: 192.168.0.50
dhcp_stop: 192.168.0.150
in_inventory: 192.168.0.[50:150]
di_dist: "{{ ansible_distribution_release }}"
di_version: 10 #"{{ ansible_distribution_major_version }}"
@ -49,8 +50,8 @@
roles:
- up2date-debian
- two-interface-firewalld
- dhcp-dns-dnsmasq
- tftp-netboot-installer
- netboot-installer
- dns-dhcp-tftp
- apt-cacher
- samba-ldap
- prepare4clients