Description of problem:
When vhost frontend plugin is enabled on node, jenkins build will throw some error, while mod-rewrite does not.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1.Install node, and enable vhost frontend plugin on this node.
2.Create an ruby app, and add jenkins-client
3.Do some change, then git push to trigger jenkins build.
During jenkins build, the following error is seen in the output:
remote: /opt/rh/ruby193/root/usr/share/ruby/json/common.rb:155:in `parse': 757: unexpected token at '<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> (JSON::ParserError)
remote: <title>502 Proxy Error</title>
remote: <h1>Proxy Error</h1>
remote: <p>The proxy server received an invalid
remote: response from an upstream server.<br />
remote: The proxy server could not handle the request <em><a href="/job/scaruby19app-build/api/json">GET /job/scaruby19app-build/api/json</a></em>.<p>
remote: Reason: <strong>Error reading from remote server</strong></p></p>
remote: <address>Apache/2.2.15 (Red Hat) Server at jenkinsapp-jialiu.ose-21.com.cn Port 443</address>
remote: from /opt/rh/ruby193/root/usr/share/ruby/json/common.rb:155:in `parse'
remote: from /var/lib/openshift/53da4913f13a7963780000e8/jenkins-client//bin/jenkins_build:27:in `get_jobs_info'
remote: from /var/lib/openshift/53da4913f13a7963780000e8/jenkins-client//bin/jenkins_build:46:in `is_cancelled'
remote: from /var/lib/openshift/53da4913f13a7963780000e8/jenkins-client//bin/jenkins_build:70:in `<main>'
remote: Deployment Halted!
remote: If the build failed before the deploy step, your previous
remote: build is still running. Otherwise, your application may be
remote: partially deployed or inaccessible.
remote: Fix the build and try again.
remote: An error occurred executing 'gear postreceive' (exit code: 1)
Though jenkins build failed, the change takes effect.
If wait for some minutes (e.g: 5 mins), do jenkins build again, no error is seen.
No error is seen in the output.
When enable mod-rewrite frontend plugin, no such issue.
I tried this a few times and couldn't reproduce the problem. Is there an element of timing to it? (E.g. only happens on an update within X minutes of creating the app...) Or perhaps it's just gone away with the latest 2.2.
I was able to reproduce this. It seems like there's some sort of timeout problem. I could fine 502s in /var/log/httpd/openshift_log matching the failed jenkins jobs.
In the jenkins logs I saw this error message around the time of the failure:
INFO: Checking to see if slave DNS for app2bldr-demo.ose22.example.com is resolvable ... (timeout: 300000ms)
I didn't see that error message for every 502 so I'm not completely convinced it's related. In all cases the problem seemed to go away which is what is making it even harder to track down.
I'm going to propose we treat this as high priority for 2.2.z.
*** Bug 1176649 has been marked as a duplicate of this bug. ***
Created attachment 972621 [details]
Created attachment 972622 [details]
Verified this bug with 2.2/2015-03-18.2 puddle, PASS.
remote: Executing Jenkins build.
remote: You can track your build at https://jenkins-jialiu.ose-22.example.com/job/php53app-build
remote: Waiting for build to schedule..............................Done
remote: Waiting for job to complete............Retrying job 1 lookup....Done.
remote: New build has been deployed.
remote: Git Post-Receive Result: success
remote: Deployment completed with status: success
$ curl php53app-jialiu.ose-22.example.com|grep title
<title>We22lcome to OpenShift</title>
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.