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

codebeamer Application Lifecycle Management (ALM)

Search In Project

Search inClear

Tags:  GitHub Webhook

Configure GitHub Webhook

This page demonstrates the configuration of GitHub Webhook.

Make sure there is a codebeamer user with the same username as the pusher in GitHub or use the pusher email (see below)
Make sure there is no repository in the project with the same name.


Configure codebeamer

Actions to be taken in codebeamer:

  1. Create user(s) who has the same username as the pusher(s) in GitHub
  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 does not exist in your json (json root level)
  • Add "github" node if it does not exist in your json under "scc" node
  • Add "secretToken":"<secret_token_of_the_webhook>" under "github" node

Example:

Configure GitHub Webhook

Steps to configure GitHub webhook:

  • Navigate to the Settings page of a repository
  • Choose Webhooks menu
  • Click to Add webhook
  • Fill out the fields
    • Payload URL: <codebeamer_url>/rest/scm/github/<project_id>
      Where codebeamer_url is the url of your codebeamer and project_id is the id of your project where the GitHub repository will belong to after the first webhook execution
      Example: https://codebeamer.com/cb/rest/scm/github/1
    • Content type: application/json
    • Secret: codebeamer validates the source of the requests with the Secret Token. It is required to set the same SecretToken in GitHub and in codebeamers's Application Configuration too (see above)
  • Select Enable SSL verification or Disable (not recommended) according to your codebeamer server SSL configuration
  • Select Just the push event (codebeamer supports only push event)
  • Click on [Add webhook]

Configure GitHub Email Address Privacy

This feature is available since codebeamer 9.5.

In case there is no user in codebeamer with the same username as the pusher in GitHub, codebeamer will use the user for repository operations who has the same email address as the pusher.

Make sure GitHub use the correct email address in webhooks.

For more information, see: https://help.github.com/en/articles/setting-your-commit-email-address#setting-your-commit-email-address-on-github