summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2022-01-21 08:59:26 +0100
committerGitHub <noreply@github.com>2022-01-21 08:59:26 +0100
commitec5eb00bd83a235492d3742bf3f80c604f5206dd (patch)
tree79189cf601fb2f4644fd3837611fbbfc80bdb4cd
parent93cdb6f1ca00723f77f013203f946a256f36a7e3 (diff)
parent28a92e75cf931c54423e2441ebf85ab3629e59b4 (diff)
downloadvyos-1x-ec5eb00bd83a235492d3742bf3f80c604f5206dd.tar.gz
vyos-1x-ec5eb00bd83a235492d3742bf3f80c604f5206dd.zip
Merge pull request #1180 from goodNETnick/dhcp-client-prefix
DHCP: T4196: fix client-prefix-length parameter
-rw-r--r--data/templates/dhcp-server/dhcpd.conf.tmpl2
1 files changed, 1 insertions, 1 deletions
diff --git a/data/templates/dhcp-server/dhcpd.conf.tmpl b/data/templates/dhcp-server/dhcpd.conf.tmpl
index 233e2cc53..da2f28ced 100644
--- a/data/templates/dhcp-server/dhcpd.conf.tmpl
+++ b/data/templates/dhcp-server/dhcpd.conf.tmpl
@@ -165,7 +165,7 @@ shared-network {{ network | replace('_','-') }} {
option wpad-url "{{ subnet_config.wpad_url }}";
{% endif %}
{% if subnet_config.client_prefix_length is defined and subnet_config.client_prefix_length is not none %}
- option subnet-mask {{ subnet_config.client_prefix_length }};
+ option subnet-mask {{ ('0.0.0.0/' ~ subnet_config.client_prefix_length) | netmask_from_cidr }};
{% endif %}
{% if subnet_config.lease is defined and subnet_config.lease is not none %}
default-lease-time {{ subnet_config.lease }};