From b5b6e657ca7f59e21bdc52b975b0f454b9da523f Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sun, 5 May 2019 14:55:35 +0200 Subject: [dhcp-server] T103: wrong hostnames in hosts file (cherry picked from commit 09df82d3a4ff2e0912992cb5c73d5d9fce7070dd) --- src/conf_mode/dhcp_server.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/conf_mode/dhcp_server.py') diff --git a/src/conf_mode/dhcp_server.py b/src/conf_mode/dhcp_server.py index 26c25333e..8dc08563e 100755 --- a/src/conf_mode/dhcp_server.py +++ b/src/conf_mode/dhcp_server.py @@ -184,7 +184,7 @@ shared-network {{ network.name }} { {%- endif -%} {%- for host in subnet.static_mapping %} {% if not host.disabled -%} - host {{ network.name }}_{{ host.name }} { + host {% if host_decl_name -%} {{ host.name }} {%- else -%} {{ network.name }}_{{ host.name }} {%- endif %} { fixed-address {{ host.ip_address }}; hardware ethernet {{ host.mac_address }}; {%- if host.static_parameters %} -- cgit v1.2.3