docker-maven-plugin
docker-maven-plugin copied to clipboard
Remote DOCKER_HOST configuration does not support ssh protocol
Description
When setting the remote docker host over ssh using DOCKER_HOST environment variable like below
export DOCKER_HOST="ssh://user@remotehost"
The plugin fails with below error
ClientProtocolException: ssh protocol is not supported
Why SSH?
I can open the tcp port for remote docker daemon but doing that involves additional configurations at firewall and service side, also setting ssl authentication is an additional overhead, since I've set the ssh passwordless authentication already it would be great if the plugin supports connection over ssh
How to reproduce
- Set DOCKER_HOST environment variable with ssh connection details, like
export DOCKER_HOST="ssh://user@remotehost"
- Run the maven build
Software:
- docker version: 19.03.13
- docker-maven-plugin version: 0.34.1
- maven version: 3.6.3
stacktrace
[ERROR] Failed to execute goal io.fabric8:docker-maven-plugin:0.34.1:build (default-cli) on project command-builder: Cannot create docker access object : ClientProtocolException: ssh protocol is not supported ->
Is there any way for this to be enabled? Since docker has added support this has been used more and more. It might just be that the schema needs to be updated to include ssh, and docker can take it from there.
I second dezren39 -- ssh support would be very welcome!
need this feature too
Indeed, dmp only support TCP, via remote or UNIX sockets. I agree that this would be a great addition to dmp but we don't have the bandwidth to add any bigger features to dmp. However, I you feel fancy we are happy about any contributions. I think the connection abstraction with dmp is quite nice, so it should not be impossible (but still quite some work).
Also, before you want to start on this, let me know so that we can align on any ssh dependency that might be needed to include.