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

Assign the global default route to an specific connection when possible #1368

Merged
merged 3 commits into from
Nov 7, 2024

Conversation

teclator
Copy link
Contributor

@teclator teclator commented Nov 6, 2024

Problem

The default gateway is lost after installation if the gateway is configured manually and it’s not network interface specific. It’s the wicked to NM conversion that is not implemented in this case.

Solution

When the default route does not belongs to any specific interface it will be associated to the connection which has an ip address belonging to the same network than the default route gateway.

Testing

  • Added a new unit test
  • Tested manually

@coveralls
Copy link

coveralls commented Nov 6, 2024

Coverage Status

coverage: 80.591% (+0.007%) from 80.584%
when pulling 0c3f1c3 on write_default_route
into a115bdc on SLE-15-SP5.

@teclator teclator changed the base branch from master to SLE-15-SP6 November 7, 2024 09:48
@teclator teclator changed the base branch from SLE-15-SP6 to master November 7, 2024 09:49
@teclator teclator changed the base branch from master to SLE-15-SP5 November 7, 2024 10:12
Copy link
Contributor

@imobachgs imobachgs left a comment

Choose a reason for hiding this comment

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

Just two minor comments. Otherwise, it looks good.

src/lib/y2network/network_manager/config_writer.rb Outdated Show resolved Hide resolved
src/lib/y2network/network_manager/config_writer.rb Outdated Show resolved Hide resolved
@teclator teclator merged commit 0e992e4 into SLE-15-SP5 Nov 7, 2024
10 checks passed
@teclator teclator deleted the write_default_route branch November 7, 2024 15:22
@yast-bot
Copy link
Contributor

yast-bot commented Nov 7, 2024

✔️ Internal Jenkins job #771 successfully finished
✔️ Created IBS submit request #353029

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.

4 participants