Docker Community Forums

Share and learn in the Docker community.

1> How can I ssh into container in the docker. 2> What is the configuration should be done in docker file to build image

(Nalinipantham) #1

1> I have build image through docker file and could not create slave through jenkins and getting the following error

[08/09/16 17:28:58] [SSH] Opening SSH connection to
Connection refused: connect
ERROR: Unexpected error in launching a slave. This is probably a bug in Jenkins.
e[8mha:AAAAWB+LCAAAAAAAAP9b85aBtbiIQSmjNKU4P08vOT+vOD8nVc8DzHWtSE4tKMnMz/PLL0ldFVf2c+b/lb5MDAwVRQxSaBqcITRIIQMEMIIUFgAAckCEiWAAAAA=e[0mjava.lang.IllegalStateException: Connection is not established!
at com.trilead.ssh2.Connection.getRemainingAuthMethods(
at com.cloudbees.jenkins.plugins.sshcredentials.impl.TrileadSSHPasswordAuthenticator.canAuthenticate(
at com.cloudbees.jenkins.plugins.sshcredentials.SSHAuthenticator.newInstance(
at com.cloudbees.jenkins.plugins.sshcredentials.SSHAuthenticator.newInstance(
at hudson.plugins.sshslaves.SSHLauncher.openConnection(
at hudson.plugins.sshslaves.SSHLauncher$
at hudson.plugins.sshslaves.SSHLauncher$
at Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$ Source)
at Source)
[08/09/16 17:28:59] Launch failed - cleaning up connection

Could some one help on this due to the above error slaves created are going offline in jenkins

(Nathan Le Claire) #2

Usually you don’t run sshd in containers or SSH into them – instead I recommend docker exec -ti <container> sh to spawn a shell inside of the container