[Feature Request] Make Docker Socket feature protocol aware #35

Closed
opened 2025-11-19 07:12:32 -06:00 by GiteaMirror · 0 comments
Owner

Originally created by @beefstew809 on GitHub (Jun 7, 2025).

I am trying to use the new DOCKER_SOCKET option that was recently released. Instead of exposing /var/run/docker.sock directly, I am using a socket-proxy container (lscr.io/linuxserver/socket-proxy - https://docs.linuxserver.io/images/docker-socket-proxy) to help secure my environment more.

If I set DOCKER_SOCKET=tcp://socket-proxy:2375 then I receive back the log Docker socket check response sent: available=false. Note that socket-proxy is the name of my container. It could be any name or port after the tcp:// portion.

It looks like the code looks specifically for /var/run/docker.sock and that it does not accept TCP protocols (it is specifically looking for unix).

See:

50b621f17c/docker/client.go (L52-L59)

I think it will be more than just doing a check and accepting TCP in the above function as I see the code is appending unix to the socketPath at 50b621f17c/docker/client.go (L83)

Request: Make the code protocol aware so that security enhancements such as socket-proxy can be used

Thank you for your condsideration and for this awesome project!

Originally created by @beefstew809 on GitHub (Jun 7, 2025). I am trying to use the new `DOCKER_SOCKET` option that was recently released. Instead of exposing `/var/run/docker.sock` directly, I am using a `socket-proxy` container (`lscr.io/linuxserver/socket-proxy` - https://docs.linuxserver.io/images/docker-socket-proxy) to help secure my environment more. If I set `DOCKER_SOCKET=tcp://socket-proxy:2375` then I receive back the log `Docker socket check response sent: available=false`. Note that `socket-proxy` is the name of my container. It could be any name or port after the `tcp://` portion. It looks like the code looks specifically for `/var/run/docker.sock` and that it does not accept TCP protocols (it is specifically looking for unix). See: https://github.com/fosrl/newt/blob/50b621f17c5380ff45acd6fb394712ebf6ebd17e/docker/client.go#L52-L59 I think it will be more than just doing a check and accepting TCP in the above function as I see the code is appending unix to the `socketPath` at https://github.com/fosrl/newt/blob/50b621f17c5380ff45acd6fb394712ebf6ebd17e/docker/client.go#L83 Request: Make the code protocol aware so that security enhancements such as `socket-proxy` can be used Thank you for your condsideration and for this awesome project!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/newt#35