From 21dd4cbc3433462c0d2e7e861002b05c4cf0229f Mon Sep 17 00:00:00 2001 From: Chris Hammer Date: Fri, 14 Feb 2020 02:25:52 -0500 Subject: [PATCH] 0.1.6-DEV-20200214-22546 ------------------------ * ADD: - added support for statically assigned dhcp nodes --- templates/dhcpd_conf.j2 | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/templates/dhcpd_conf.j2 b/templates/dhcpd_conf.j2 index e9d1b2d..76d01ca 100644 --- a/templates/dhcpd_conf.j2 +++ b/templates/dhcpd_conf.j2 @@ -29,4 +29,14 @@ subnet {{ dhcp_networks[dhcp_deploy_to].subnet }} netmask {{ dhcp_networks[dhcp_ filename "{{ dhcp_pxeboot_file }}"; next-server {{ dhcp_networks[dhcp_deploy_to].pxeboot }}; + +### STATIC ASSIGNMENTS ### +{% for host in static_assignments %} + host {{ host }} + { + hardware ethernet {{ static_assignments[host]['mac_address'] }}; + fixed-address {{ static_assignments[host]['ip_address'] }}; + } +{% endfor %} + }