{"action":"created","issue":{"url":"https://api.github.com/repos/jenkinsci/docker-plugin/issues/350","labels_url":"https://api.github.com/repos/jenkinsci/docker-plugin/issues/350/labels{/name}","comments_url":"https://api.github.com/repos/jenkinsci/docker-plugin/issues/350/comments","events_url":"https://api.github.com/repos/jenkinsci/docker-plugin/issues/350/events","html_url":"https://github.com/jenkinsci/docker-plugin/issues/350","id":115969883,"number":350,"title":"Connection timeout weirdness ","user":{"login":"jwhitcraft","id":26738,"avatar_url":"https://avatars.githubusercontent.com/u/26738?v=3","gravatar_id":"","url":"https://api.github.com/users/jwhitcraft","html_url":"https://github.com/jwhitcraft","followers_url":"https://api.github.com/users/jwhitcraft/followers","following_url":"https://api.github.com/users/jwhitcraft/following{/other_user}","gists_url":"https://api.github.com/users/jwhitcraft/gists{/gist_id}","starred_url":"https://api.github.com/users/jwhitcraft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jwhitcraft/subscriptions","organizations_url":"https://api.github.com/users/jwhitcraft/orgs","repos_url":"https://api.github.com/users/jwhitcraft/repos","events_url":"https://api.github.com/users/jwhitcraft/events{/privacy}","received_events_url":"https://api.github.com/users/jwhitcraft/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-09T21:24:37Z","updated_at":"2015-11-11T15:30:00Z","closed_at":null,"body":"When trying to spin up an instance, it says it can't connect to my cloud host, but when i press the test connection button in the docker cloud, it connects just fine and shows me the correct version of docker, 1.8.2, i'm using v0.15 and v0.14 of the plugin\r\n\r\nI'm also jumping subnets, the 10.27.45 is out in AWS land where as my jenkins master is on my local machine.\r\n\r\nHere is the log.\r\n```\r\nAsked to provision 1 slave(s) for: my-docker-cloud-10.27\r\nNov 09, 2015 9:20:15 PM INFO com.nirima.jenkins.plugins.docker.DockerCloud provision\r\nWill provision 'registry.mycompany.net/my-jenkins-image:latest', for label: 'my-docker-cloud-10.27', in cloud: 'docker-cloud-10.27'\r\nNov 09, 2015 9:20:16 PM WARNING com.nirima.jenkins.plugins.docker.DockerCloud provision\r\nBad template 'registry.mycompany.net/refinery-git:latest' in cloud 'my-docker-cloud-10.27': 'shaded.org.apache.http.conn.ConnectTimeoutException: Connect to 10.27.45.26:4243 [/10.27.45.26] failed: connect timed out'. Trying next template...\r\n```"},"comment":{"url":"https://api.github.com/repos/jenkinsci/docker-plugin/issues/comments/155816836","html_url":"https://github.com/jenkinsci/docker-plugin/issues/350#issuecomment-155816836","issue_url":"https://api.github.com/repos/jenkinsci/docker-plugin/issues/350","id":155816836,"user":{"login":"pfalcon","id":500451,"avatar_url":"https://avatars.githubusercontent.com/u/500451?v=3","gravatar_id":"","url":"https://api.github.com/users/pfalcon","html_url":"https://github.com/pfalcon","followers_url":"https://api.github.com/users/pfalcon/followers","following_url":"https://api.github.com/users/pfalcon/following{/other_user}","gists_url":"https://api.github.com/users/pfalcon/gists{/gist_id}","starred_url":"https://api.github.com/users/pfalcon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pfalcon/subscriptions","organizations_url":"https://api.github.com/users/pfalcon/orgs","repos_url":"https://api.github.com/users/pfalcon/repos","events_url":"https://api.github.com/users/pfalcon/events{/privacy}","received_events_url":"https://api.github.com/users/pfalcon/received_events","type":"User","site_admin":false},"created_at":"2015-11-11T15:30:00Z","updated_at":"2015-11-11T15:30:00Z","body":"We experience this after upgrade from 0.12.1 to 0.15 (yep, we didn't upgrade for a while because the plugin is broken since 0.12.1 - if not one thing, then another).\r\n\r\nExample of our log is:\r\n\r\n~~~~\r\nINFO: Will provision 'linaro/jessie-arm64', for label: 'docker-jessie-arm64', in cloud: 'aarch64-04' Nov 09, 2015 10:13:17 PM com.nirima.jenkins.plugins.docker.DockerCloud provision WARNING: Bad template 'linaro/jessie-arm64' in cloud 'aarch64-04': 'shaded.org.apache.http.conn.ConnectTimeoutException: Connect to 10.10.0.219:2375 [/10.10.0.219] failed: connect timed out'. Trying next template...\r\n~~~~\r\n\r\nIt's not that a press \"Test Connection\", I directly telnet to 10.10.0.219, port 2375 and have HTTP speaking to me. So, \"connect timed out\" error is completely nonsensical, what can be wrong there is that plugin does something weird. And it's not possible to diagnose it, because the real exception is swallowed, and instead out-of-context message is printed: https://github.com/jenkinsci/docker-plugin/blob/master/docker-plugin/src/main/java/com/nirima/jenkins/plugins/docker/DockerCloud.java#L227\r\n\r\nPlease don't do that - ever. Especially in poor-quality code, for which jenkins plugins are infamous.\r\n"}}