Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DHCPv6 client: add missing 'use-interface-duid' option #341

Merged

Conversation

petrows
Copy link
Contributor

@petrows petrows commented Jan 26, 2025

SUMMARY

api_info, api_modify: add the use-interface-duid option for DHCPv6 client.

ISSUE TYPE
  • Feature Pull Request
COMPONENT NAME

api_info, api_modify

ADDITIONAL INFORMATION

This option prevents issues with Fritzbox modems and routers, when using virtual interfaces (like VLANs) may create duplicated records in hosts config, this breaks original "expose-host" function.

The use-interface-duid corrects this behavior: the DUID for link-local address and DHCPv6 request are the same, and user can configure per-host option in Fritzbox OS as expected.

Tested on current 7.17 and 7.16.2 versions:

--- before
+++ after
@@ -12,6 +12,7 @@
             "pool-prefix-length": 64,
             "prefix-hint": "::/59",
             "request": "address,prefix",
+            "use-interface-duid": true,
             "use-peer-dns": false
         }
     ]

Copy link

codecov bot commented Jan 26, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 84.63%. Comparing base (85d24d1) to head (3ee2a7a).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #341   +/-   ##
=======================================
  Coverage   84.63%   84.63%           
=======================================
  Files          33       33           
  Lines        4112     4112           
  Branches      879      879           
=======================================
  Hits         3480     3480           
  Misses        452      452           
  Partials      180      180           
Flag Coverage Δ
integration 66.27% <ø> (ø)
sanity 21.56% <ø> (ø)
units 84.67% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Collaborator

@felixfontein felixfontein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution!

plugins/module_utils/_api_data.py Show resolved Hide resolved
@petrows petrows force-pushed the Add-dhcpv6-use-interface-duid branch from 1c0afc2 to d136f8b Compare January 26, 2025 09:51
* script
* custom-duid
* use-interface-duid
* validate-server-duid
@petrows petrows force-pushed the Add-dhcpv6-use-interface-duid branch from d136f8b to 3ee2a7a Compare January 26, 2025 09:55
@felixfontein felixfontein merged commit 575af30 into ansible-collections:main Jan 26, 2025
30 checks passed
@felixfontein
Copy link
Collaborator

@petrows thanks again for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants