2. Integration of GitHub

The goal of integrating with GitHub is to start running the first phase in the release automatically every time there is a push to the master in your GitHub repository. Every time a change is pushed to the master, a notification is sent to Automic Continuous Delivery Director.

Configure webhook in GitHub

Follow these steps:

  • In GitHub, clone our public Automic Continuous Delivery Director repository:
    JavaScript-Sample-Application.
    This allows you to make changes to the cloned repository later on.
  • In your GitHub repository, enter the Settings tab, and click Webhooks.
  • Click Add Webhook to open the form.
  • In Payload URL enter a URL with the following syntax: webhook syntax https://cddirector.io/cdd/design/tenant_id/v1/applications/application_name/application-versions/application_version_name?username=user_name&branchName=branch_name  
    • Replace tenant_id with your tenant ID. To get the tenant ID, go to Automic Continuous Delivery Director and click on the initials at the top right corner. Select User Settings. Copy the tenant ID and paste instead of tenant_id.
    • Replace application_name with Sample Application 1 or any other name you gave to your application in Automic Continuous Delivery Director.
    • Replace application_version_name with the real application version you are currently handling in the release.
      Example: https://cddirector.io/cdd/design/tenant_id/v1/applications/MyApp/application-versions/1.5.3?username=MyUsername&branchName=master
    • Replace user_name with the user login name. This user authenticates in Automic Continuous Delivery Director and needs permission to run the phases.
      Example: cdd@gmail.com
    • Replace branch_name with the branch on which you want to be notified of changes. By default, Automic Continuous Delivery Director listens to the master branch. If you want to create a webhook on another branch, add this query parameter to the payload URL
  • In the Content-Type field, enter application/json
  • In the Secret field, paste the valid API key that matches the user name in Automic Continuous Delivery Director.
    • To get the API key, go to Automic Continuous Delivery Director and click on the initials at the top right corner.
    • Select User Settings.
    • Copy the API key.  
    • Tip: Save the API key for future use.
  • In the Event field, select push event.
    Note: Other events are not supported
  • Click Save.

The webhook supports GitHub integration in Automic Continuous Delivery Director.