How to Trigger a Build in Bamboo from Stash

How to Trigger a Build in Bamboo from Stash

A guest post by Peter Van De Voorde

Share
Share
Share
Share

This blog post will explain how to set up a Post-Receive Webhook from Stash to notify Bamboo of new changes in the repository.

We assume that there is already an integration between Stash and Bamboo. If not you can follow these instructions to set this up : Integrating Bamboo with Stash

Step-by-step guide

  1. Login to Bamboo
  2. Go to the Plan Configuration page.
  3. If the Stash Repository is already know to the plan you can skip these steps and continue with step 4.
  • Go to the Repositories tab
  • Click Add Repository
  • Fill in the details of your Stash Repository
  • Click Save Repository
  1. Go to the Triggers tab.
  2. Click Add Trigger
  3. Fill in the following data:
  • Trigger Description: A name for your trigger
  • Trigger Type: Select Repository triggers the build when changes are committed.
  • Repositories: Select the repository that will trigger this build after a change is committed.
  • Trigger IP Addresses: fill in the IP address of you repository server
  1. Click Save Trigger
  2. Login to Stash
  3. Install the following plugin if you haven’t done this already : Stash web post receive hooks plugin
  4. Go to your repository and select the settings tab
  5. Select Hooks in the left side menu
  6. Click on the pencil icon next to the Post-Receive Webhooks hook 
    Stash Peter Blog Image
  7. Fill in the following URL (replace <projectkey> and <buidkey> with your actual keys from Bamboo):
    http://<your bamboo host>/api/rest/updateAndBuild.action?buildKey=<projectkey>-<buildkey>
  8. Enable the Hook by selecting "Enabled" next to the hook.

Feel free to share this guide, you know you want to …

More about Peter Van De Voorde

Peter is a 30-something Belgian with a passion about everything Agile, during the day he’s an Atlassian Expert and ALM Consultant at RealDolmen. In the evening he’s a family man, an active member of Atlassian Answers, the Atlassian Belgian User Group and a boardgame fanatic.  Find out more at his website: www.petervandevoorde.com

Share
Share
Share
Share

Reader Interactions

Related blog articles

    Reader Interactions