Details
-
Bug
-
Resolution: Fixed
-
Low
-
4.4.1, 4.5.1, 4.6.2, 4.7.1, 4.8.0, 4.9.0, 4.10.0
-
None
-
Severity 3 - Minor
-
607
-
Description
Summary
If Bamboo is configured with Tomcat HTTPS redirection or you're running Bamboo version >= 6.8, Bitbucket Server will not trigger Bamboo on new commit
Environment
With HTTPS redirection:
- Bitbucket Server 4.6.2
- Bamboo 5.12.2
Regardless of HTTPS redirection:
- Bitbucket Server < 4.11
- Bamboo >= 6.8
Steps to Reproduce
- Configure both Bamboo and Bitbucket Server to have two connectors HTTP and HTTPS, eg server.xml:
<Connector port="80" protocol="HTTP/1.1" connectionTimeout="20000" useBodyEncodingForURI="true" redirectPort="443" compression="on" compressableMimeType="text/html,text/xml,text/plain,text/css,application/json,application/javascript,application/x-javascript" /> <Connector port="443" protocol="org.apache.coyote.http11.Http11NioProtocol" maxThreads="150" SSLEnabled="true" scheme="https" secure="true" clientAuth="false" sslProtocol="TLS" keystoreFile="/path/tokeystore.jks" keystorePass="changeit" keyAlias="test" keystoreType="JKS"/>
- Set both Bamboo and Bitbucket Server to redirect HTTP connection to HTTPS, eg WEB-INF/web.xml:
<security-constraint> <web-resource-collection> <web-resource-name>HTTPSOnly</web-resource-name> <url-pattern>/*</url-pattern> </web-resource-collection> <user-data-constraint> <transport-guarantee>CONFIDENTIAL</transport-guarantee> </user-data-constraint> </security-constraint>
- Restart Bamboo and Bitbucket Server
- Configure the Base URL for both Bamboo and Bitbucket Server to be HTTPS
- Create the Application Link between Bamboo and Bitbucket Server
- Add Bitbucket Server repo into Bamboo build plan
- Make sure that Bamboo build plan using "Bitbucket Server repository triggered"
- Push a new commit to Bitbucket Server
Expected Results
Bamboo will be triggered to build the new commit
Actual Results
Bamboo isn't triggered to build
Notes
- If Bitbucket Server have "org.apache.http.wire" debug logging, atlassian-bitbucket.log does not show any POST request to Bamboo when a new commit is pushed
- If Bamboo have "org.apache.http.wire" debug logging, there is a POST request to Bitbucket Server after a build finish
Workaround
These do not apply to Bamboo versions >= 6.8. Bitbucket will need to be upgraded if using Bamboo >= 6.8.
- Remove HTTP->HTTPS redirection in Bamboo and then restart Bamboo and Bitbucket Server
OR - Add an additional Trigger "Repository polling" to all Plan Configuration