Move DHCP service to dns1.p.b

The DHCP server on the UniFi Security Gateway is pretty limited; it
cannot manage static leases (reservations), and does not offer any way
to build dynamic values for e.g. hostname or boot filename. Rather than
give up these features, I decided to just move the DHCP server to one of
the Raspberry Pis; the DNS server made the most sense.

To facilitate this move, I created the *pyrocufflink-dhcp* host group,
and moved the DHCP configuration variables there. Thus, it was a simple
matter of adding *dns1.pyrocufflink.blue* to this group to relocate the
service.

Of course, to serve clients on the other subnets, the gateway needs to
have DHCP relay enabled and pointing to the new server.
This commit is contained in:
2018-10-07 11:56:58 -05:00
parent 36675d0523
commit 9f32f94780
2 changed files with 16 additions and 9 deletions

View File

@@ -20,6 +20,7 @@ dhcp_subnets:
end: 172.30.0.253
routers:
- 172.30.0.241
dns_servers: '{{ dch_networks.mgmt.dns_servers_v4 }}'
ntp_servers: '{{ dch_networks.mgmt.ntp_servers }}'
# pyrocufflink.blue
@@ -58,8 +59,8 @@ dhcp_subnets:
routers:
- 172.24.100.1
dns_servers:
- 208.67.222.222
- 208.67.220.220
- 1.1.1.1
- 1.0.0.1
ntp_servers:
- 0.fedora.pool.ntp.org
- 1.fedora.pool.ntp.org
@@ -92,12 +93,9 @@ dhcp_reservations:
mac_addr: 52:54:00:aa:5c:01
# pyrocufflink.blue
- host: dc0.pyrocufflink.blue
ip_addr: 172.30.0.10
mac_addr: 52:54:00:e0:fa:f9
- host: dc1.pyrocufflink.blue
ip_addr: 172.30.0.9
mac_addr: b8:27:eb:0d:db:19
- host: dns1.pyrocufflink.blue
ip_addr: 172.30.0.3
mac_addr: b8:27:eb:1b:d9:23
- host: dns0.pyrocufflink.blue
ip_addr: 172.30.0.4
mac_addr: 52:54:00:b8:8b:64
@@ -110,6 +108,12 @@ dhcp_reservations:
- host: zbx0.pyrocufflink.blue
ip_addr: 172.30.0.7
duid: ff:4a:0e:44:56:00:02:00:00:ab:11:ef:11:04:5c:28:85:54:96
- host: dc1.pyrocufflink.blue
ip_addr: 172.30.0.9
mac_addr: b8:27:eb:0d:db:19
- host: dc0.pyrocufflink.blue
ip_addr: 172.30.0.10
mac_addr: 52:54:00:e0:fa:f9
- host: diddy.pyrocufflink.blue
ip_addr: 172.30.0.13
mac_addr: 74:da:38:8f:94:4f

5
hosts
View File

@@ -28,7 +28,7 @@ dch-gw
vm-hosts
[dhcpd:children]
dch-gw
pyrocufflink-dhcp
[file-servers]
file0.pyrocufflink.blue
@@ -82,6 +82,9 @@ vmhost0.pyrocufflink.blue
web0.pyrocufflink.blue
zbx0.pyrocufflink.blue
[pyrocufflink-dhcp]
dns1.pyrocufflink.blue
[pyrocufflink-dns]
dns0.pyrocufflink.blue
dns1.pyrocufflink.blue