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

Extend p2p functionality to k0s #691

Merged
merged 17 commits into from
Mar 12, 2025
Merged

Extend p2p functionality to k0s #691

merged 17 commits into from
Mar 12, 2025

Conversation

mauromorales
Copy link
Member

@mauromorales mauromorales commented Feb 14, 2025

Adds support for mesh network with k0s distro. The detection of the distro is done by either having explicit config or by the binary installed. By default, it uses k3s, for backwards compatibility.

Additionally, I refactored to split responsibilities. master.go will have generic logic on how the steps to setup a master node, and worker.go a worker node. It does so by interacting with the K8sNode interface, and the detailed logic on how to do it for each distribution has been moved to k3s.go and k0s.go respectively. This should make it much simpler to debug or add new distributions.

Tests:

  • k3s single
  • k3s multi manual
  • k3s p2p auto
  • k0s single
  • k0s multi manual
  • k0s p2p auto

Covered:

Sorry, something went wrong.

@mauromorales mauromorales requested a review from a team February 14, 2025 09:17
@mauromorales mauromorales self-assigned this Feb 14, 2025
@mauromorales mauromorales changed the title WIP Extend p2p functionality to k0s Extend p2p functionality to k0s Feb 19, 2025
@mauromorales mauromorales marked this pull request as ready for review February 19, 2025 22:00
@mauromorales mauromorales requested review from a team and removed request for a team February 19, 2025 22:01
@mauromorales
Copy link
Member Author

fixes kairos-io/kairos#3151

@mauromorales
Copy link
Member Author

debugging p2p auto since there's an issue with pods not starting properly because they cannot contact the controller node

@mauromorales
Copy link
Member Author

Issue that was causing the failed pods has been fixed now. It's also properly setting the edgvpn IP instead of the local IP. I still need to test this on different networks though and see if the nods can talk to each other via edgevpn

@mauromorales
Copy link
Member Author

@jimmykarily ok addressed the things I wanted to get fixed, if you have some time please have a look

mauromorales and others added 9 commits March 11, 2025 10:43

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <contact@mauromorales.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <contact@mauromorales.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <contact@mauromorales.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <contact@mauromorales.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <contact@mauromorales.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
Lint

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <contact@mauromorales.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
Lint

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>

Verified

This commit was signed with the committer’s verified signature.
mauromorales Mauro Morales
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
@mauromorales
Copy link
Member Author

fixes kairos-io/kairos#3151

@jimmykarily
Copy link
Contributor

@jimmykarily ok addressed the things I wanted to get fixed, if you have some time please have a look

I tested again and it works locally with 2 VMs created with virt-manager.

@mauromorales mauromorales merged commit c5c4bad into main Mar 12, 2025
12 of 13 checks passed
@mauromorales mauromorales deleted the k0s-p2p branch March 12, 2025 10:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

3 participants