Triggering a build from Bitbucket Cloud using the Remote trigger (legacy)

Learn how to set up the Remote trigger to kick off a Bamboo build from Bitbucket Cloud after certain events like creating a branch or pull request, or pushing a commit.

Using this method of triggering builds from Bitbucket Cloud is no longer recommended and should only be used to troubleshoot legacy integrations with Bitbucket Cloud. For new integrations, we recommend that you use webhooks. See Triggering a Bamboo build from Bitbucket Cloud using Webhooks.

  1. Configure the Bamboo plan to use the Remote trigger:
    1. From the plan configuration page, select ActionsConfigure planTriggersAdd triggerRemote trigger.
    2. Select Scheduled or Single daily build depending on the times you want your build to run.
    3. Bamboo displays the available repositories for the plan, as previously configured in the Source repositories tab. Optionally, enter a trigger description. Select the repositories that this trigger should apply to.
    4. In the Trigger IP addresses field, add the IP addresses of the request sources as a comma-separated list.

      For the current list of Bitbucket Cloud IP addresses for outbound POST requests by webhooks, see Bitbucket Cloud IP Addresses.

      When configuring trigger IP addresses, consider the following:

      • CIDR Notation is only supported in Bamboo 5.14 or newer.
      • Bamboo's IP allowlist also inspects the X-Forwarded-For HTTP header to determine the origin of the request. If you have a reverse proxy forwarding request to your Bamboo instance, depending on its configuration, you may also need to add the IP address of the proxy server to the allowlist.
    5.  Select Save trigger.
  2. Add the IP addresses of the request sources to the trigger
  3. In Bitbucket Cloud, add a webhook from the repository:
    1. Select Bitbucket Cloud > Repository > Settings > Webhooks > Add webhook.
    2. Specify any title for your Webhook that aptly describes it.
    3. Enter the URL of the Bamboo API to trigger a plan as follows:
      <BAMBOO_URL>/rest/triggers/1.0/remote/changeDetection?planKey=<PLAN-KEY>&skipBranches=false
      where <BAMBOO_URL> is the URL of your Bamboo instance and <PLAN_KEY> is the key identifying the plan you want to trigger.

      tip/resting Created with Sketch.

      You can get the plan key from your browser's address bar when viewing the plan in Bamboo.

      The skipBranches parameter determines whether change detection is triggered by this event for every branch on the plan (false) or just for the specified plan key (true).

    4. Select your preferred trigger types.
    5. 変更を保存します。
最終更新日 2022 年 8 月 25 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.