Bitbucket Plugin

This topic describes how to configure the XL Release Bitbucket plugin.

Prerequisites

  • Install the Bitbucket plugin into the XLR plugins/xlr-official folder.

Requirements

  • Bitbucket Cloud running and accessible.
  • Bitbucket Server running and accessible.
  • XL Release running and accessible.

Configuration

  • You need to have information about URL, username and password to connect with Bitbucket cloud and Bitbucket server.
  • Create a Shared Configuration for your Bitbucket Cloud and Bitbucket Server.
  • Create a Shared Configuration for your HTTP Endpoint For Webhooks.

Set up a connection to the Bitbucket Cloud

  1. In the top navigation bar, click Settings > Shared configuration.
  2. Under configurations, beside Bitbucket: Cloud, click Add button
  3. In the Title field, enter a name for the configuration.
  4. In URL, enter the URL where the Bitbucket cloud is running.
  5. In Username, enter the Bitbucket cloud username.
  6. In Password, enter the Bitbucket cloud password.
  7. Click Test, to test the connection.
  8. Click Save, to save the configuration.

XLR_Bitbucket-cloud_CONNECTION

Set up a connection to the Bitbucket Server

  1. In the top navigation bar, click Settings > Shared configuration.
  2. Under configurations, beside Bitbucket: Server, click Add button
  3. In the Title field, enter a name for the configuration.
  4. In URL, enter the URL where the Bitbucket server is running.
  5. In Username, enter the Bitbucket server username.
  6. In Password, enter the Bitbucket server password.
  7. Click Test, to test the connection.
  8. Click Save, to save the configuration.

XLR_Bitbucket-server_CONNECTION

Features

  • Bitbucket cloud commit trigger configuration - This trigger can be used to poll the Bitbucket cloud for triggering releases.

  • Bitbucket server commit trigger configuration - This trigger can be used to poll the Bitbucket server for triggering releases.

  • Create bitbucket cloud/server tasks.

    • Tasks of bitbucket cloud -

      • Bitbucket Cloud: Create Pull Request
      • Bitbucket Cloud: Merge Pull Request
      • Bitbucket Cloud: Wait for Pull Request
      • Bitbucket Cloud: Commit List
      • Bitbucket Cloud: Download Code
    • Tasks of bitbucket server -

      • Bitbucket Server: Create Branch
      • Bitbucket Server: Delete Branch
      • Bitbucket Server: Create Pull Request
      • Bitbucket Server: Approve Pull Request
      • Bitbucket Server: Merge Pull Request
      • Bitbucket Server: Decline Pull Request
      • Bitbucket Server: Get Pull Request
      • Bitbucket Server: Wait For Merge
      • Bitbucket Server: Commit Query
      • Bitbucket Server: Download Code
      • Bitbucket Server: Tag Release
      • Bitbucket Server: Search File Content
  • Create webhooks event for the Bitbucket cloud/server.
  • Add Bitbucket cloud/server tiles on the release dashboard.

Set up a connection for Webhooks

  1. In the top navigation bar, click Settings > Shared configuration.
  2. Under configurations, beside HTTP Endpoint For Webhooks under Webhooks and Events section, click Add button
  3. Select POST endpoint in the HTTP Endpoint for Webhooks field.
  4. Enabled checkbox should be enabled.
  5. In the Title field, enter a name for the configuration.
  6. In Endpoint path, enter the endpoint path.
  7. Select No authentication in Authentication Method field.
  8. Click Save, to save the configuration.

XLR_webhooks_cloud_CONNECTION XLR_webhooks_server_CONNECTION

Tile and Dashboard configuration for Bitbucket Cloud

There are four tiles in Bitbucket cloud:

  • Bitbucket Cloud Commits Summary
  • Bitbucket Cloud Contributions Summary
  • Bitbucket Cloud Merge Requests Summary
  • Bitbucket Cloud Commits Timeline
  • In the top navigation bar, click Reports.
  • Select the dashboard where you want to add the new tile. Note: If you have not created a dashboard yet, you can do so by clicking the Add dashboard button in the top right of the screen.
  • In the top right of the screen, click Configure dashboard.
  • In the top right of the screen, click Add tiles.
  • Hover over Bitbucket Cloud Commits Summary, and click Add.
  • Click the Configure option present in the tile.
  • In the Title field, enter a name for the tile.
  • In the Bitbucket Cloud field, select the cloud configured.
  • In the Repository Full name field, enter the name of the repository.
  • In the Branch Name field, enter the name of branch from which data can be fetched.
  • In the Tag Name field, enter the tag name.
  • In the Results Limit field, enter the limit of list in numbers.
  • Click Save.

You can configure for rest of the three tiles of the Bitbucket cloud using the same process described above.

XLR_Dashboard_cloud_CONNECTION

Tile and Dashboard configuration for Bitbucket Server

There are four tiles in Bitbucket server:

  • Bitbucket Server Commits Summary
  • Bitbucket Server Contributions Summary
  • Bitbucket Server Merge Requests Summary
  • Bitbucket Server Commits Timeline
  • In the top navigation bar, click Reports.
  • Select the dashboard where you want to add the new tile. Note: If you have not created a dashboard yet, you can do so by clicking the Add dashboard button in the top right of the screen.
  • In the top right of the screen, click Configure dashboard.
  • In the top right of the screen, click Add tiles.
  • Hover over Bitbucket Server Commits Summary, and click Add.
  • Click the Configure option present in the tile.
  • In the Title field, enter a name for the tile.
  • In the Bitbucket Server field, select the server configured.
  • In the Project Name field, enter the project key.
  • In the Project Slug field, enter the name of the repository.
  • In the Branch Name field, enter the name of branch from which data can be fetched.
  • In the Tag Name field, enter the tag name.
  • In the Results Limit field, enter the limit of list in numbers.
  • Click Save.

You can configure for rest of the three tiles of the Bitbucket server using the same process described above.

XLR_Dashboard_server_CONNECTION

Report creation

  1. Click Reports.
  2. Go to Audit report.
  3. Click the Generate new report button.
  4. Select Time period.
  5. Click Add filter to generate the report for a specific template.
  6. Click the Preview results button.
  7. Click the Generate report button.
  8. Download the generated report.
  9. Extract it and verify the extracted reports.

Release notes

Release Bitbucket plugin 9.8.0

  • [ENG-1579] - Initial release/Insourcing.