-
Notifications
You must be signed in to change notification settings - Fork 1.1k
transport module supporting remote connections though ssh #1440
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
Conversation
# Conflicts: # docker-java/src/test/java/com/github/dockerjava/cmd/CmdIT.java # pom.xml
# Conflicts: # docker-java-transport-ssh/src/test/java/com/github/dockerjava/jsch/SsshWithOKDockerHttpClientIT.java # docker-java/src/test/java/com/github/dockerjava/cmd/CmdIT.java
revert ci workflow to include non-ssh runs
@mwiede thanks for submitting the PR! I will review it soon, but meanwhile, could you please revert all non-relevant changes (like the imports reordering or indentation changes)? Thanks in advance! |
@bsideup Alright, I removed the import ordering stuff. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
@bsideup Did you manage to take a look at this pull request? Now, with the new Docker Desktop story, the landscape is somewhat changing making this feature more needed that ever 😉 |
Sorry, I am afraid the change is too involved to be considered added, as docker-java is a low level library, and SSH seems to be a "meta" transport. Will consider making it easy to provide custom SocketFactories to existing transports. |
Maybe some more info and a possible fix for those facing the same issue. |
@rob-valor I am trying to release the transport-module I created as an independent package. With #1818 this is now possible and users should be able to use this as described on getting_started. I will update this once I have it released |
@rob-valor both Rancher Desktop and Podman work fine with docker-java (and Testcontainers) without the SSH transport. Examples: |
FYI I have released the code of this at https://github.com/mwiede/docker-java-transport-jsch |
Only if you are able to install them locally, that is not the case in my company, so we need to use a remote podman :( |
As mentioned in #1130 I wrote a transport module, which supports connections through ssh.
For the ssh connection I used Jsch library, for the http client, I used OKhttp. I guess both libraries can be replaced with alternatives, but for now, I started like this.
I needed to extend the testing setup a little bit, so that any test for the new transport module only connects though ssh. So now, in the ci, there are two maven builds with conditionals, as well as in
com.github.dockerjava.cmd.CmdIT
.There are several ways to connect to the docker daemon on the remote site, as I explained in https://github.com/mwiede/docker-java/blob/master/docker-java-transport-ssh/Readme.md
Feedback welcome!