Bamboo agent behind proxy

Alexander Belozerov September 3, 2018

Hi,

I'm trying to configure Bamboo remote agent located in a closed cluster network. As a proxy server, I use Squid on cluster managment node which have access to bamboo server host . The agent setup is failing with message:

INFO   | jvm 1    | 2018/09/03 21:23:27 | 2018-09-03 21:23:27,452 INFO [AgentRunnerThread] [AgentRegistrationBean] Registering agent on the server,

INFO   | jvm 1    | 2018/09/03 21:27:42 | 2018-09-03 21:27:42,644 ERROR [ActiveMQ Task-1] [FailoverTransport] Failed to connect to [tcp://<bamboo server host>:54663?wireFormat.maxInactivityDuration=300000] after: 10 attempt(s)

How correctly to set up a proxy for JMS connection? HTTP/HTTPS proxying works well through -Dhttps.proxyHost, -Dhttps.proxyPort, -Dhttp.proxyHost and -Dhttp.proxyPort options.

Thanks.

1 answer

0 votes
Anonymous Coward
Contributor
September 11, 2018

Simon says:

" The JMS connection is configured on your Bamboo server to use the TCP transport. This means that on the remote agent side you would need to use a forward proxy that can proxy TCP connections.

Since you are running Squid (which proxies HTTP/HTTPS maninly) you can change the transport in the JMS configuration to HTTP or HTTPS. If you use the latter please don't forget to set certificates correctly.

To change the JMS transport edit the file <Bamboo home directory>/bamboo.cfg.xml (which is located on your Bamboo server) and edit the lines below to use TCP transport (http was used below):

<property name="bamboo.jms.broker.client.uri">failover:(http://<bamboo_server_hostname>:54663?wireFormat.maxInactivityDuration=300000)?maxReconnectAttempts=10&amp;initialReconnectDelay=15000</property>
<property name="bamboo.jms.broker.uri">nio://0.0.0.0:54663</property>

(Make sure to replace <bamboo_server_hostname> with the actual hostname).

Restart your Bamboo server to apply the changes. The remote agent reads these properties once it connects to the server via the Base URL and then attempts the JMS connection.

"

Simon out.

Alexander Belozerov September 11, 2018

There was new error:

INFO | jvm 68 | 2018/09/12 10:17:49 | 2018-09-12 10:17:49,490 INFO [Acti
erty> │veMQ Task-1] [DefaultHttpClient] Retrying request to {}->http://bamboo-server:54663

INFO   | jvm 68   | 2018/09/12 10:18:42 | 2018-09-12 10:18:42,851 INFO [ActiveMQ Task-1] [DefaultHttpClient] I/O exception (java.net.SocketException) caught when processing request to {}->http://bamboo-server:54663: Connection reset

When trying to access http://bamboo-server:54663 i receive page with something about ActiveMQ. What blocks Java http client from accessing this page?

Anonymous Coward
Contributor
September 19, 2018

Simon says:

" Check your forward proxy logs for connection termination as well as the Bamboo server logs for Active MQ entries.

You can increase log verbosity on the remote agent and the Bamboo server to get more information. Use this page to find the classes to adjust the verbosity level: https://confluence.atlassian.com/bamkb/how-to-increase-debug-logging-to-investigate-remote-agent-problems-939925299.html

"

Simon out.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events