Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Hudson » launch a Jenkins slave running off a docker image that runs on my Linux AMI (AWS)(I'm trying to figure out how to launch a Jenkins slave running off a docker image that runs on my Linux AMI (AWS))
launch a Jenkins slave running off a docker image that runs on my Linux AMI (AWS) [message #1759253] Sat, 08 April 2017 20:14 Go to next message
John Okrasa is currently offline John OkrasaFriend
Messages: 2
Registered: April 2017
Junior Member
I'm trying to figure out how to launch a Jenkins slave running
off a docker image that runs on my Linux AMI (AWS) so it's Centos based.

My objective is to use it to demo the https:_//www.docker.com/use-cases/cicd

this is a current demo on the docker main site that unfortunately doesn't go into enough detail in setting things up
and is also maybe dated/deprecated as to the current jenkins version.

firstly the simplest approach...

If I try "launch agent via Java Web Start" it doesn't connect to host at port 50000 which is open on the host

but in the demo they do.. launch slave agents via SSH

so...

put ec2-35-162-139-187.us-west-2.compute.amazonaws.com as the host

under credentials -> add -> Kind

the choices are:

-docker host certificate authorization
-SSH username with private key
-Secret file
-Secret Text
-Certifcate

so I have an EC2.pem file which is PEM or Privacy Enhanced Mail is a Base64 encoded DER certificate
this is how with PuttyGen ( creates a ppk file off the pem file ) I connect to the Linux ami (centos) server.
and installed jenkins through docker cs engine.

So trying to select it as a Secret file then launching the Slave yeilds the following error..

[04/07/17 18:04:54] [SSH] Opening SSH connection to ec2-35-162-139-187.us-west-2.compute.amazonaws.com:22.
/var/jenkins_home/.ssh/known_hosts [SSH] No Known Hosts file was found at /var/jenkins_home/.ssh/known_hosts. Please ensure one is created at this path and that Jenkins can read it.
Key exchange was not finished, connection is closed.
java.io.IOException: There was a problem while connecting to ec2-35-162-139-187.us-west-2.compute.amazonaws.com:22
at com.trilead.ssh2.Connection.connect(Connection.java:818)
at com.trilead.ssh2.Connection.connect(Connection.java:687)
at com.trilead.ssh2.Connection.connect(Connection.java:601)
at hudson.plugins.sshslaves.SSHLauncher.openConnection(SSHLauncher.java:1265)
at hudson.plugins.sshslaves.SSHLauncher$2.call(SSHLauncher.java:790)
at hudson.plugins.sshslaves.SSHLauncher$2.call(SSHLauncher.java:785)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.io.IOException: Key exchange was not finished, connection is closed.
at com.trilead.ssh2.transport.KexManager.getOrWaitForConnectionInfo(KexManager.java:93)
at com.trilead.ssh2.transport.TransportManager.getConnectionInfo(TransportManager.java:230)
at com.trilead.ssh2.Connection.connect(Connection.java:770)
... 9 more
Caused by: java.io.IOException: The server hostkey was not accepted by the verifier callback
at com.trilead.ssh2.transport.KexManager.handleMessage(KexManager.java:535)
at com.trilead.ssh2.transport.TransportManager.receiveLoop(TransportManager.java:777)
at com.trilead.ssh2.transport.TransportManager$1.run(TransportManager.java:489)
... 1 more
[04/07/17 18:04:54] Launch failed - cleaning up connection
[04/07/17 18:04:54] [SSH] Connection closed.

Is there any guide as to how to configure a jenkins slave on linu
Re: launch a Jenkins slave running off a docker image that runs on my Linux AMI (AWS) [message #1759329 is a reply to message #1759253] Mon, 10 April 2017 07:27 Go to previous message
Bob Foster is currently offline Bob FosterFriend
Messages: 85
Registered: January 2013
Member
This appears to be a Jenkins question. Please see

https://wiki.jenkins-ci.org/display/JENKINS/Asking+for+Help
Previous Topic:Tagging a build in CVS via hudson...
Next Topic:Build failed.. git project.. help me~~~
Goto Forum:
  


Current Time: Wed Jun 28 14:22:58 GMT 2017

Powered by FUDForum. Page generated in 0.02828 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software