Triggering a Bamboo build from Jira Automation
The purpose of this guide is to help you set up a webhook that will trigger a Bamboo build from Jira after a certain event occurs. For example, you may want to trigger a Bamboo build when a Jira issue changes its status.
To do so, you need to configure a Remote trigger for your plan in Bamboo, and create a new rule trigger in Jira Automation that will connect to the Remote trigger with a webhook.
Before you begin
Make sure that your Bamboo instance is publicly available and has a valid certificate.
To configure a Remote trigger for your Bamboo plan:
From the Bamboo header select Build > All build plans.
Select the plan you want to set up a trigger for.
Select Actions > Configure plan, then select the Triggers tab.
Select Add trigger > Remote trigger and complete the form.
Note that Bamboo requires you to add to the allowlist the IP addresses of the source of the request to trigger under the Trigger IP addresses field (comma separated for each IP). Select the IP addresses you want to add to the allowlist from the list of IP addresses for Atlassian cloud products.Select Save trigger.
To create a new Jira Automation rule trigger:
In your Jira project, go to Project settings > Automation > Create rule.
Select your trigger type, then select Save.
Select the New action component type, and select Send web request.
Enter the URL of your Bamboo API:
BAMBOO_URL/rest/triggers/1.0/remote/changeDetection?planKey=PLAN-KEY&skipBranches=false
, where:BAMBOO_URL
is the URL of your Bamboo instance.PLAN-KEY
is the key of the plan you wish to trigger. ThePLAN-KEY
is visible in the URL when browsing the plan in Bamboo. E.g. https://bamboo.atlassian.com/browse/PLAN-KEY.skipBranches true / false determines whether change detection will be triggered by this event for every branch on the plan (false), or just the plan key specified (true).
Set the HTTP method to POST.
Set the Webhook body option to Empty.
(Optional) Select the Validate your webhook configuration option to test your connection.
Select Save. Your trigger is ready!