fix: userspace wireguard library overrides#11204
Merged
talos-bot merged 1 commit intosiderolabs:mainfrom Jun 12, 2025
Merged
Conversation
Drop using the fork https://github.com/siderolabs/wireguard-go which had a single change to the variable. Instead, patch the variable using Go linker flags and only for `machined`. This fixes the issue with `wg` utility not working for `talosctl cluster create --with-siderolink` clsuters, as it was using incompatible path. We do need to override the path for Talos only, as in Talos `/var/run` is not always available, but outside of Talos itself we never need this change at all. Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
Member
Author
|
So to make it more clear:
|
utkuozdemir
approved these changes
Jun 12, 2025
Orzelius
approved these changes
Jun 12, 2025
Member
Author
|
/m |
smira
added a commit
to smira/talos
that referenced
this pull request
Oct 29, 2025
This is a fix for the wrong fix in siderolabs#11204, which was wrong in two ways: * the ldflags -X override had a wrong variable name, so it had no effect * but the above even if it worked, only covered "mamangement" part of things, while `wgctrl-go` which configures things still has a hardcoded location of `/var/run/`. So the fix is two ways: * replace the location where the socket is created properly * use updated forked wgctrl-go which looks in both locations This keeps all fixes of siderolabs#11204 - `talosctl cluster create` siderolink agent works properly with `wg` on the host, and Talos uses proper location. Before the fix the location was actually `/var/run` and it randomly failed depending on the race condition of Talos booting up and managing `/var`. Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
smira
added a commit
to smira/talos
that referenced
this pull request
Oct 30, 2025
This is a fix for the wrong fix in siderolabs#11204, which was wrong in two ways: * the ldflags -X override had a wrong variable name, so it had no effect * but the above even if it worked, only covered "mamangement" part of things, while `wgctrl-go` which configures things still has a hardcoded location of `/var/run/`. So the fix is two ways: * replace the location where the socket is created properly * use updated forked wgctrl-go which looks in both locations This keeps all fixes of siderolabs#11204 - `talosctl cluster create` siderolink agent works properly with `wg` on the host, and Talos uses proper location. Before the fix the location was actually `/var/run` and it randomly failed depending on the race condition of Talos booting up and managing `/var`. Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
shanduur
pushed a commit
to shanduur/talos
that referenced
this pull request
Nov 5, 2025
This is a fix for the wrong fix in siderolabs#11204, which was wrong in two ways: * the ldflags -X override had a wrong variable name, so it had no effect * but the above even if it worked, only covered "mamangement" part of things, while `wgctrl-go` which configures things still has a hardcoded location of `/var/run/`. So the fix is two ways: * replace the location where the socket is created properly * use updated forked wgctrl-go which looks in both locations This keeps all fixes of siderolabs#11204 - `talosctl cluster create` siderolink agent works properly with `wg` on the host, and Talos uses proper location. Before the fix the location was actually `/var/run` and it randomly failed depending on the race condition of Talos booting up and managing `/var`. Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com> (cherry picked from commit d69305a)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Drop using the fork https://github.com/siderolabs/wireguard-go which had a single change to the variable.
Instead, patch the variable using Go linker flags and only for
machined.This fixes the issue with
wgutility not working fortalosctl cluster create --with-siderolinkclsuters, as it was using incompatible path.We do need to override the path for Talos only, as in Talos
/var/runis not always available, but outside of Talos itself we never need this change at all.