diff options
author | Vasyl Saienko <vsaienko@mirantis.com> | 2017-09-21 13:39:28 +0000 |
---|---|---|
committer | Vasyl Saienko <vsaienko@mirantis.com> | 2017-10-13 12:50:58 +0300 |
commit | 228a2a7885e1b04d4180fe8daa2992884decaf6d (patch) | |
tree | 7b18d9d711cb09a31fa18e21ecd186106281b57d /ironic/common/dhcp_factory.py | |
parent | 2d486ca8c0b1ed9251a76945457e0fc28239e7ac (diff) | |
download | ironic-228a2a7885e1b04d4180fe8daa2992884decaf6d.tar.gz |
Change pxe dhcp options name to codes.
There is difference between dhcp option names in different backends.
This patch changes options name to code according to [0].
[0] https://www.iana.org/assignments/bootp-dhcp-parameters/bootp-dhcp-parameters.xhtml
Closes-Bug: 1717236
This is an updated version of c377f5cbbd034e16b68a3fc30e138b03badc9c94
which problems with PXE and dnsmasq due to buggy dnsmasq code which uses
siaddr field to specify tftp server. They are addressed now by always
sending server-ip-address to make sure that dnsmasq works.
More information about siaddr and option 150,66 can be found in
informational RFC https://tools.ietf.org/html/rfc5859
Change-Id: I55487d867979bf6bb4cf228fcf6408beae955d2b
Diffstat (limited to 'ironic/common/dhcp_factory.py')
-rw-r--r-- | ironic/common/dhcp_factory.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/ironic/common/dhcp_factory.py b/ironic/common/dhcp_factory.py index aaff635df..fa294cb46 100644 --- a/ironic/common/dhcp_factory.py +++ b/ironic/common/dhcp_factory.py @@ -72,12 +72,10 @@ class DHCPFactory(object): :: - [{'opt_name': 'bootfile-name', + [{'opt_name': '67', 'opt_value': 'pxelinux.0'}, - {'opt_name': 'server-ip-address', - 'opt_value': '123.123.123.456'}, - {'opt_name': 'tftp-server', - 'opt_value': '123.123.123.123'}] + {'opt_name': '66', + 'opt_value': '123.123.123.456'}] :param ports: A dict with keys 'ports' and 'portgroups' and dicts as values. Each dict has key/value pairs of the form |