YouTrack Standalone 2017.3 Help

Bitbucket Integration

You can integrate a project in YouTrack with a Bitbucket repository. A Bitbucket integration enables the following features in YouTrack:

Prerequisites

  • Your YouTrack server must be accessible from the Internet.

  • The account that you use to connect to Bitbucket is either the owner of the repository or has admin-level access to the repository. This is the user account whose login and password are used for authentication. If you use an account that does not have admin-level access to the repository, you encounter an unable to perform operation error.

  • A committer's email address in YouTrack must be the same as in Bitbucket. YouTrack searches for a user account based on the email address that is registered in Bitbucket. These users must also have permission to update issues in the connected YouTrack project. If no match is found or the user does not have the required permission, the commands are not applied.

  • You are able to access the Bitbucket server with an email address and password. The YouTrack integration with Bitbucket does not support two-step verification.

Configure the Bitbucket Integration

When you enable and configure the Bitbucket integration, you define mappings between a YouTrack project and a Bitbucket repository.

As an administrator, you can enable the Bitbucket integration for any project in YouTrack.

To enable the Bitbucket integration:

  1. Open the Administration > VCS Integrations page.

  2. Click the New VCS Integration button.
    • The New VCS Integration dialog opens in the sidebar.

      ytVCSGitHubAdd thumbnail

  3. From the Server drop-down list, select bitbucket.org.

  4. Enter the login and password for the Bitbucket account.

  5. If you are not the repository owner, provide the repository owner name. If you are the owner of the repository, leave the field blank.

  6. Click the Connect to VCS server button.
    • The New VCS Integration dialog displays settings for mapping the VCS to your project.

      ghIntegrationSettings thumbnail

  7. Enter values for the following settings:

    Setting

    Description

    YouTrack Project

    Select the YouTrack project that you use to track changes to the code repository.

    Repository

    Select the repository where you store the source code that is related to the selected project.

    Committers

    Select the group that contains all of the users who can commit changes to the selected repository.

    Monitor Branches

    Enter the names of the branches that you want to monitor for changes. Use the plus sign to include a branch and the minus sign to exclude a branch. For more information, see Monitor Branches.

    Visible for Groups

    Select one or mor groups to restrict the visibility of comments and updates on the VCS Changes tab. Otherwise, the list of changes that are displayed on this tab is visible to any user who has permission to read issues in the project.

  8. Click the Save button.
    • The Bitbucket repository is associated with the selected YouTrack project.

      NewBitbucketIntCreated thumbnail

    • Commits from the Bitbucket repository that mention an issue in the project are displayed in the VCS Changes tab of the mentioned issue.

Troubleshooting

If you experience problems setting up the GitLab integration, see if the following condition applies.

Condition

You are unable to save the new VCS integration settings. YouTrack returns the error unable to perform operation.

Cause

The login and password that are used for authentication with Bitbucket belong to a user who is not the owner of the repository and does not have admin-level access. This integration uses webhooks, which can only be created by the owner of the repository and other users who are granted admin access.

Solution

Access the User and group access settings for your repository and grant admin access to the user you are using to authenticate with Bitbucket. You can also grant admin access to a group where this user is a member.

Alternatively, use the login and password of an account that is already granted admin access in the repository.

Last modified: 7 March 2019

See Also