-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Issue with ApacheDockerHttpClient Handling unix:// Connections #2380
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
Comments
Yes, I can second this. Encountering the same issue. In addition: I just tried to bypass this bug by switching to Zerodep. Sadly this issue occurs there as well. So i'd suspect the base DockerHttpClient to have this issue. |
I am third one to encountering this issue. Do you have any updates about solving this issue? @latamsystems @Severon96 |
@muhammetbolat I ended up not using this Library. |
For everyone, the best alternative is OkDockerHttpClient |
@latamsystems no it actually isn't, since it's maintenance, stability and security isn't fully ensured on a long term basis. |
Using OkDockerHttpClient solved my problem. Thank you @Severon96 @latamsystems However, they could not have any long term support plan for OkDockerHttpClient. They put question mark on transport.md file. They must be solve or must support this client in future. `
` |
Hi all, I experience the issue as well. I could track that issue down to an incompatability in Apache HttpClient between versions 5.2.1 and 5.4.1 . Tracking the issue further brought me to https://issues.apache.org/jira/browse/HTTPCLIENT-2348 where the developer of Apache HttpClient states about docker-java
This issue also brought me to #2364 which seems to upgrade docker-java to Apache HttpClient 5.4.2 and fix incompatibiltites. Release and review might be delayed at least until end of March according to @eddumelendez . Here are some workarounds for the meantime:
|
This issue duplicates #2363 |
Closing as duplicate |
Hi Docker-Java-Devs,
I hope you're doing well.
I wanted to bring to your attention an issue I've encountered with the ApacheDockerHttpClient when connecting to Docker via a Unix socket (unix://). Specifically, when the client detects a unix:// connection, it automatically changes the host to localhost:2375. This behavior causes issues when the Docker host is intended to be a Unix socket, and not TCP.
This seems to be problematic both on Linux and Windows environments, as it tries to connect to the wrong endpoint (localhost), resulting in the following error:
Interestingly, this issue does not occur when using the OkHttpDockerHttpClient. The OkHttp client correctly handles the unix:// scheme without trying to alter the connection to localhost, which resolves the issue.
It would be great if we could review and potentially update the handling of unix:// connections in ApacheDockerHttpClient to prevent this automatic conversion to localhost.
Let me know if you need any further details or assistance on this.
Best regards,
Luis Miguel Vasquez
Java Developer
The text was updated successfully, but these errors were encountered: