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

Feature request: add support for unix domain socket #654

Open
AurelienRichez opened this issue Apr 27, 2023 · 2 comments · May be fixed by #680
Open

Feature request: add support for unix domain socket #654

AurelienRichez opened this issue Apr 27, 2023 · 2 comments · May be fixed by #680

Comments

@AurelienRichez
Copy link

Feature request: add support for unix domain socket

Just discovered the project. This looks really nice.

go grpc implementation supports unix sockets. I wanted to know if you would consider adding support in evans as well.

From what I see it is already almost working if we set as an address unix:///path/to/socket. evans already tries to connect via the unix socket protocol but the only issue seems to be that evans concatenate the port no matter what

addr := fmt.Sprintf("%s:%s", cfg.Server.Host, cfg.Server.Port)

As a consequence the file name is wrong and evans cannot connect (I guess that it could work if the socket was awkwardly named like socket:123 😅)

I could get it to work by not adding the :<port> part if the address starts with unix://, so the fix looks simple (but there are other things to do for completeness, probably to add tests and change the prompt in the repl).

I can try to work on it and open a PR if you are interested (I'm not very familiar with go and the project itself, so if someone else is faster than me even better).

@yuzhichang
Copy link

+1 for debuging k8s CRI which's address is unix:///var/run/crio/crio.sock

@flokli flokli linked a pull request Oct 8, 2023 that will close this issue
@flokli
Copy link
Contributor

flokli commented Oct 8, 2023

I did quickly create a patch for it and sent it over at #680, but I'd assume in the long term, we might want to deprecate host and port cmdline args in favor of a single address arg.

It's obviously up to the maintainer on how this should go in, so let's see how it goes 🤞

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 a pull request may close this issue.

3 participants