diff --git a/manifests/pool.pp b/manifests/pool.pp index 9c010850e..bf6a859f6 100644 --- a/manifests/pool.pp +++ b/manifests/pool.pp @@ -8,6 +8,7 @@ $parameters = '', $nameservers = undef, $pxeserver = undef, + $domain_name = '', ) { include dhcp::params diff --git a/templates/dhcpd.pool.erb b/templates/dhcpd.pool.erb index 651d19169..5977d7e72 100644 --- a/templates/dhcpd.pool.erb +++ b/templates/dhcpd.pool.erb @@ -18,6 +18,9 @@ subnet <%= @network %> netmask <%= @mask %> { } <% end -%> +<% if @domain_name and !@domain_name.empty? -%> + option domain-name <%= @domain_name %>; +<% end -%> option subnet-mask <%= @mask %>; <% if @gateway != '' -%> option routers <%= @gateway %>;