Code Monkey home page Code Monkey logo

Comments (12)

djl197 avatar djl197 commented on June 27, 2024

If I create a slave node manually and enter the same details.
Then when the slave is launched via Docker - it is able to connect to it and run.
So I am even more confused as the why the SSHLauncher call in getSSHLauncher is not working :-(

from docker-plugin.

thomassuckow avatar thomassuckow commented on June 27, 2024

There has been an ongoing issue where Jenkins attempts to SSH before the docker container is ready, retrying seems to be hit an miss. If I had to guess I would say this is related. In my setup, frequently it can take several minutes/attempts of bringing a container up and down for Jenkins to connect.

from docker-plugin.

djl197 avatar djl197 commented on June 27, 2024

I think I have solved this now :-) Will post some updates once I am sure

from docker-plugin.

colegleason avatar colegleason commented on June 27, 2024

Any update on this? I'm also experiencing this issue.

from docker-plugin.

djl197 avatar djl197 commented on June 27, 2024

I have played around a bit - and I now have a configurable delay before attempting to SSH to the container.
That seems to have solved it for me - so in the plugin I have a per container setting (default 30seconds). With this change it works a whole lot better and generally gets in first attempt rather than failing 3 times and then rerunning the container.

from docker-plugin.

thomassuckow avatar thomassuckow commented on June 27, 2024

I wonder if we could open our own tcp connection with a short timeout, if it connects then call it good, if it fails sleep 1 second.

I also wonder what the EC2 plugin does...

from docker-plugin.

colegleason avatar colegleason commented on June 27, 2024

@djl197 I'd love to see that delay back in the master plugin!

from docker-plugin.

Intrepidd avatar Intrepidd commented on June 27, 2024

Hello, still seing this painful issue, anyone came up with a valid solution ?

from docker-plugin.

KostyaSha avatar KostyaSha commented on June 27, 2024

@thomassuckow did you have chance to look on ec2 plugin (or other)?

from docker-plugin.

thomassuckow avatar thomassuckow commented on June 27, 2024

EC2 seems to go the custom route.
https://github.com/jenkinsci/ec2-plugin/blob/master/src/main/java/hudson/plugins/ec2/ssh/EC2UnixLauncher.java

I get the feeling though that some people are running docker on slower machines and it takes a while for SSH to come up. In which case, we probably just have to be more tolerant of retrying. We used to have a lot more issues with containers failing to start at all which made the shorter tries more beneficial, but that it behind us now (knock on wood).

I have not noticed this issue for a while now, though I am also running the bleeding edge. A lot has changed since 0.8.

from docker-plugin.

KostyaSha avatar KostyaSha commented on June 27, 2024

@thomassuckow should we suggest using some slave reconnect plugin (if it exist) and will it work?

from docker-plugin.

thomassuckow avatar thomassuckow commented on June 27, 2024

I think we just need to tune how we call SSH Slaves Plugin.

from docker-plugin.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.