diff options
| author | Patrick Felt <fatpelt@gmail.com> | 2026-03-25 06:53:05 +0000 |
|---|---|---|
| committer | Patrick Felt <fatpelt@gmail.com> | 2026-03-25 06:53:05 +0000 |
| commit | 41d56f9cc0cbf3ab7b893e9f686b8adbc85f8b63 (patch) | |
| tree | d714669811b0cef65938003e8f26b5881584a724 /python | |
| parent | fbae51d4683e97fd9f32b5f1d71b903e728cdca3 (diff) | |
| download | vyos-1x-41d56f9cc0cbf3ab7b893e9f686b8adbc85f8b63.tar.gz vyos-1x-41d56f9cc0cbf3ab7b893e9f686b8adbc85f8b63.zip | |
kea: T8408: Fixes to enable dhcp option 67
- Kea overloads the meaning of the boot-file-name option. When used on
its own, it represents the legacy bootp filename option. When option
67 is needed, boot-file-name must be included in an options block.
Diffstat (limited to 'python')
| -rw-r--r-- | python/vyos/kea.py | 13 | ||||
| -rwxr-xr-x | python/vyos/template.py | 1 |
2 files changed, 14 insertions, 0 deletions
diff --git a/python/vyos/kea.py b/python/vyos/kea.py index a8b38d999..733e7cf86 100644 --- a/python/vyos/kea.py +++ b/python/vyos/kea.py @@ -165,6 +165,7 @@ def kea_parse_subnet(subnet, config): if 'bootfile_name' in config['option']: out['boot-file-name'] = config['option']['bootfile_name'] + out['option-data'].append({"name": "boot-file-name", "data": config['option']['bootfile_name']}) if 'bootfile_server' in config['option']: out['next-server'] = config['option']['bootfile_server'] @@ -193,6 +194,12 @@ def kea_parse_subnet(subnet, config): if 'bootfile_name' in range_config['option']: pool['boot-file-name'] = range_config['option']['bootfile_name'] + pool['option-data'].append( + { + "name": "boot-file-name", + "data": range_config['option']['bootfile_name'] + } + ) if 'bootfile_server' in range_config['option']: pool['next-server'] = range_config['option']['bootfile_server'] @@ -229,6 +236,12 @@ def kea_parse_subnet(subnet, config): reservation['boot-file-name'] = host_config['option'][ 'bootfile_name' ] + reservation['option-data'].append( + { + "name": "boot-file-name", + "data": host_config['option']['bootfile_name'] + } + ) if 'bootfile_server' in host_config['option']: reservation['next-server'] = host_config['option'][ diff --git a/python/vyos/template.py b/python/vyos/template.py index 2a783bc74..d2fb5c1e0 100755 --- a/python/vyos/template.py +++ b/python/vyos/template.py @@ -1031,6 +1031,7 @@ def kea_shared_network_json(shared_networks): if 'bootfile_name' in config['option']: network['boot-file-name'] = config['option']['bootfile_name'] + network['option-data'].append({"name": "boot-file-name", "data": config['option']['bootfile_name']}) if 'bootfile_server' in config['option']: network['next-server'] = config['option']['bootfile_server'] |
