Bamboo running behind a reverse proxy

I am continuing this thread: . The basis is that I am running bamboo, and other atlassian products, behind a reverse proxy. I am not using Apache but HAProxy and Stunnel. The atlassian products need to be on SSL since we are using crowd with LDAP integration and we don't want authentication in the clear.

The problem is that bamboo on login will execute a GET /%2Fstart.action that results in directing to http instead of https, causing a page not found. Even though I have the proxy redirecting http requests to the bamboo domain, it doesn't redirect these requests since it isn't a post. The login is successful and if I simply tack the resulting URL: and change to , then I am delivered to the dashboard. Once in, I am largely able to navigate around without issue, though randomly at times it still tries to redirect to http or will loose context and redirect to the login again.

Any idea how to fix this?

**We want to have our SSL on a load balancer proxy so we are consolidating our certificates and we can maintain all internal traffic in http rather than having the SSL load on a per server instance. This configuration works well for Jira, with no real issues but bamboo forms causes grief.

Further Findings

I recently setup confluence 3.5 in a similar manner as bamboo above. The confluence standalone tomcat instance communicated to the reverse proxy in http. The rever proxy then handles the SSL encryption/decryption to the end user (the proxy is the SSL termination). When the user attempts login to confluence, the redirect on login goes to http://{BASE_URL}/%2fstart.action instead of https://{BASE_URL}/%2Fstart.action. If you change the URL to the correct version, then you get directed to the dashboard and all is good. The login is successful. I would say this is a minor annoyance but trying to expose this site to customers in its current state is impossible. Seems like a bug.

3 answers

1 accepted

So the solution: You need to run bamboo via Tomcat. Discard the jetty standalone and get the WAR. Then setup bamboo on Tomcat. You can then change the parameters of the connector in the server.xml file to include proxyName, scheme, and proxyPort.

Do you have scheme="https" proxyPort="443" in your tomcat connector in server.xml? Adding them should fix your proxy issue with confluence. I acutally run my bamboo in tomcat as well because I didn't know how to set the same thing up in jetty.

I do have that already setup. However, I believe I found the real problem. HAProxy acts out of the box as Apache with ProxyPreserveHost On, that is it forwards the Host on to the server rather than the specified URL. Turning this off in Apache will solve the problem (I know since I setup Apache as proxy for these instances as a test). But I cannot find equivalent config for HAProxy. Asked teh mailing list and will post if I find out.

There's another simple solution to this, you can just use mod rewrite in your http vhost configuration that catches this request:

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteCond %{REQUEST_URI} ^/bamboo
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}

Suggest an answer

Log in or Join to answer
Community showcase
Louis De Jaeger
Posted yesterday in Off-topic

Friday fun: your best joke

Hi all Lets make this Friday fun really fun and post one (or more) of your best jokes! The joke can be about an Atlassian product, or just a really fun joke you want to share! I’m not the best j...

84 views 2 2
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot