From d10892a326ef3e0ee1e89795c82befd0bd43b847 Mon Sep 17 00:00:00 2001 From: linhng <39908250+linhng98@users.noreply.github.com> Date: Sun, 13 Feb 2022 10:00:27 +0700 Subject: [PATCH] fix: use ip lease range based on network cidr (#41) Co-authored-by: Nguyen Van Linh --- metal/roles/pxe_server/templates/dhcpd.conf.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/metal/roles/pxe_server/templates/dhcpd.conf.j2 b/metal/roles/pxe_server/templates/dhcpd.conf.j2 index 483d7b1d..ae5ded00 100644 --- a/metal/roles/pxe_server/templates/dhcpd.conf.j2 +++ b/metal/roles/pxe_server/templates/dhcpd.conf.j2 @@ -7,7 +7,7 @@ option architecture-type code 93 = unsigned integer 16; subnet {{ ansible_default_ipv4.network }} netmask {{ ansible_default_ipv4.netmask }} { option routers {{ ansible_default_ipv4.gateway }}; - range {{ ansible_default_ipv4.gateway | ansible.netcommon.ipmath(1) }} {{ ansible_default_ipv4.broadcast | ansible.netcommon.ipmath(-1) }}; + range {{ ansible_default_ipv4.network | ansible.netcommon.ipmath(1) }} {{ ansible_default_ipv4.broadcast | ansible.netcommon.ipmath(-1) }}; class "pxeclients" { match if substring (option vendor-class-identifier, 0, 9) = "PXEClient";