-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
nmcli: Treat order as significant when comparing address lists #6048
nmcli: Treat order as significant when comparing address lists #6048
Conversation
Don't sort the old and new values for ipv4.addresses and ipv6.addresses before comparing them, because order matters in these parameters: the first address specified is the default source address for outbound connections.
Co-authored-by: Felix Fontein <felix@fontein.de>
If nobody objects, I'll merge this this weekend. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Backport to stable-5: 💚 backport PR created✅ Backport PR branch: Backported as #6081 🤖 @patchback |
* nmcli: Treat order as significant when comparing address lists Don't sort the old and new values for ipv4.addresses and ipv6.addresses before comparing them, because order matters in these parameters: the first address specified is the default source address for outbound connections. * Changelog fragment for #6048 * Update changelogs/fragments/6048-nmcli-addres-order.yml Co-authored-by: Felix Fontein <felix@fontein.de> --------- Co-authored-by: Felix Fontein <felix@fontein.de> (cherry picked from commit 682c6fc)
Backport to stable-6: 💚 backport PR created✅ Backport PR branch: Backported as #6082 🤖 @patchback |
* nmcli: Treat order as significant when comparing address lists Don't sort the old and new values for ipv4.addresses and ipv6.addresses before comparing them, because order matters in these parameters: the first address specified is the default source address for outbound connections. * Changelog fragment for #6048 * Update changelogs/fragments/6048-nmcli-addres-order.yml Co-authored-by: Felix Fontein <felix@fontein.de> --------- Co-authored-by: Felix Fontein <felix@fontein.de> (cherry picked from commit 682c6fc)
@jikamens thanks again for your contribution! |
…ant when comparing address lists (#6081) nmcli: Treat order as significant when comparing address lists (#6048) * nmcli: Treat order as significant when comparing address lists Don't sort the old and new values for ipv4.addresses and ipv6.addresses before comparing them, because order matters in these parameters: the first address specified is the default source address for outbound connections. * Changelog fragment for #6048 * Update changelogs/fragments/6048-nmcli-addres-order.yml Co-authored-by: Felix Fontein <felix@fontein.de> --------- Co-authored-by: Felix Fontein <felix@fontein.de> (cherry picked from commit 682c6fc) Co-authored-by: Jonathan Kamens <jik@kamens.us>
…ant when comparing address lists (#6082) nmcli: Treat order as significant when comparing address lists (#6048) * nmcli: Treat order as significant when comparing address lists Don't sort the old and new values for ipv4.addresses and ipv6.addresses before comparing them, because order matters in these parameters: the first address specified is the default source address for outbound connections. * Changelog fragment for #6048 * Update changelogs/fragments/6048-nmcli-addres-order.yml Co-authored-by: Felix Fontein <felix@fontein.de> --------- Co-authored-by: Felix Fontein <felix@fontein.de> (cherry picked from commit 682c6fc) Co-authored-by: Jonathan Kamens <jik@kamens.us>
Docs Build 📝Thank you for contribution!✨ This PR has been merged and your docs changes will be incorporated when they are next published. |
…le-collections#6048) * nmcli: Treat order as significant when comparing address lists Don't sort the old and new values for ipv4.addresses and ipv6.addresses before comparing them, because order matters in these parameters: the first address specified is the default source address for outbound connections. * Changelog fragment for ansible-collections#6048 * Update changelogs/fragments/6048-nmcli-addres-order.yml Co-authored-by: Felix Fontein <felix@fontein.de> --------- Co-authored-by: Felix Fontein <felix@fontein.de>
Don't sort the old and new values for ipv4.addresses and ipv6.addresses before comparing them, because order matters in these parameters: the first address specified is the default source address for outbound connections.
SUMMARY
The
nmcli
module (before this change) treated the order of IPv4 or IPv6 addresses for an interface as insignificant, i.e., it would not consider it a change for the order of these addresses to change. This is not correct, since the first address for an interface is the default address for outbound connections, so order matters. The change in this PR continues to treat order as insignificant for other list settings, but treats order as significant for ipv4.addresses and ipv6.addresses.ISSUE TYPE
COMPONENT NAME
nmcli