You are not logged in. Click here to log in.

codebeamer Application Lifecycle Management (ALM)

Search In Project

Search inClear

Tags:  not added yet

Configure self hosted Bitbucket webhook

Please note bitbucket repository integration is limited to the repositories created by individual bitbucket user accounts
Make sure there is no repository in the codebeamer project with the same name
Use Existing External Repository is not supported! The webhook execution after the first push will create the repository.

Configure codebeamer

There are 2 things to do in codebeamer:

  1. Create user(s) who has the same username as the pusher(s) in Bitbucket.
  2. Add the secret token of the webhook to codebeamer configuration (see below)

Steps to configure secret token in codebeamer:

  • Go to codebeamer's System Admin page
  • Go to Application Configuration
  • Add "scc" node if it is not exist in your json (json root level)
  • Add "bitbucket" node if it is not exist in your json under "scc" node
  • Add "secretToken":"<secret_token_of_the_webhook>" under "bitbucket" node
  • Add "baseUrl":"<base_url>" under "bitbucket" node
    Where base_url is the base url of your bitbucket server i.e.: http://localhost:7990
    IMPORTANT NOTE: With the version of 9.5.0-LTS containerized codebeamer instance, base_url have to be closed with forward slash!
  • Add "username": "<bitbucket_username>" under "bitbucket" node
    Where bitbucket_username is a bitbucket username who has access to the repository. It is necessary for Bitbucket API calls
  • Add "password":"<bitbucket_password>" under"bitbucket" node
    Where bitbucket_password is the password for the given bitbucket user. It is necessary for Bitbucket API calls. After you save the configuration the password will be encrypted
  • Add "secretToken":"<secret_token_of_the_webhook>" under "bitbucket" node

Example:

Configure Bitbucket webhook

Steps to configure bitbucket webhook:

  • Navigate to the Settings page of a repository
  • Choose Webhooks menu
  • Click on Add webhook
  • Fill out the fields
    • Name: Title of your choice
    • URL: <codebeamer_url>/rest/scm/bitbucket/<project_id>
      Where codebeamer_url is the url of your codebeamer and project_id is the id of your project where the Bitbucket repository will belong to after the first webhook execution
      Example: https://codebeamer.com/cb/rest/scm/bitbucket/1
    • Secret: codebeamer validates the source of the requests with the Secret Token. It is required to set the same Secret Token in Bitbucket and in codebeamers's Application Configuration too (see above)
  • Status: Active; checked (default)
  • Check/Uncheck SSL/TLS according to your codebeamer server SSL/TLS configuration
  • Triggers: Repository push (codebeamer supports only push event)
  • Click on Save