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

Use UNIX socket patch from url struct #1186

Merged

Conversation

klemensn
Copy link
Contributor

@klemensn klemensn commented Oct 8, 2024

No need to extract it again when the url package provides it for us:

$ jq -n '{"AdminListen":"unix:///tmp/ygg.sock"}' | ./yggdrasil -useconf | grep 'admin socket'
2024/10/08 22:41:11 UNIX admin socket listening on /tmp/ygg.sock

Follow-up on #1176

No need to extract it again when the url package provides it for us:
```
$ jq -n '{"AdminListen":"unix:///tmp/ygg.sock"}' | ./yggdrasil -useconf | grep 'admin socket'
2024/10/08 22:41:11 UNIX admin socket listening on /tmp/ygg.sock
```

Follow-up on yggdrasil-network#1176
Copy link
Member

@neilalexander neilalexander left a comment

Choose a reason for hiding this comment

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

Looks good at first glance but can you please just check this does the right thing when there are complex characters in the file path that may or may not be URL-encoded?

@klemensn
Copy link
Contributor Author

klemensn commented Oct 9, 2024

Looks good at first glance but can you please just check this does the right thing when there are complex characters in the file path that may or may not be URL-encoded?

It now decodes URL encoded file paths, e.g. unix:///tmp/y%40gg.sock becomes /tmp/y%40gg.sock / /tmp/[email protected] with master / this PR, respectively.

@neilalexander neilalexander merged commit a642939 into yggdrasil-network:develop Oct 17, 2024
20 checks passed
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