---
title: "Connecting Pipelines to your GitHub repo"
date: "2024-02-14T06:18:38+00:00"
summary: "Streamline your development workflow by connecting Acquia Pipelines to your GitHub repository. Learn the requirements, step-by-step process, and how to manage webhooks for seamless integration and automated builds."
image:
type: "page"
url: "/acquia-cloud-platform/connecting-pipelines-your-github-repo"
id: "3967c10e-5c77-43b5-8150-b1164f4e23f7"
---

Pipelines enables you to integrate your Acquia-hosted application with version control repositories hosted by GitHub.com.

Requirements
------------

Before you connect Cloud Platform to your repository, ensure you meet the requirements for your repository, based on the following:

*   _If you don’t already have a GitHub repository,_ [sign in to your GitHub account](https://github.com), and then visit [github.com/new](https://github.com/new) to create a new repository from the GitHub interface.
*   _If you have an existing repository,_ add GitHub as a new remote by modifying your project repository’s local clone with the following code (where `[username]` is your GitHub username and `[project]` is the name of your project):
    
        git remote add github git@github.com:[username]/[project].git
        git push github master
    

Connecting to your Github repository
------------------------------------

To connect to your GitHub repository:

Note

To connect to your GitHub repository through a command-line client, see [Managing your Pipelines from the command line](/acquia-cloud-platform/features/pipelines/cli).

1.  [Sign in to the Cloud Platform user interface](/node/55875).
2.  Click the name of the application you want to connect to GitHub.
3.  In the left menu, click **Pipelines**. If your application doesn’t display a **Pipelines** link, [contact Acquia Support](/service-offerings/support#contact-acquia-support).
4.  In the **Select Source** section, click the **Choose source** link.
    
    ![Selecting source](https://acquia.widen.net/content/4n5mk4msyr/jpeg/pipelines_selecting-github-source.jpg?crop=false&position=c&q=80&color=ffffffff&u=0b06mk&w=821&h=321)
    
5.  Click **Configure**.
    
    ![Configuring GitHub](https://acquia.widen.net/content/b98ou370k1/jpeg/pipelines_configuring-github.jpg?crop=false&position=c&q=80&color=ffffffff&u=0b06mk&w=821&h=404)
    
6.  In the **Configure Pipelines with your GitHub repository** section, click **Configure**.
    
    ![Clicking the Configure link](https://acquia.widen.net/content/t4h8z1relj/jpeg/pipelines_clicking-the-configure-link.jpg?crop=false&position=c&q=80&color=ffffffff&u=0b06mk&w=821&h=321)
    
7.  Click **Connect to GitHub**.
8.  In the GitHub user interface, click **Authorize** to grant access of your GitHub repository to Cloud Platform. Cloud Platform displays a page containing your environment’s Pipelines information.
9.  Click **Select GitHub repository**.
10.  Select the repository to which you want to connect, and click **Continue**.

Each time you use GitHub to create or reopen a pull request, push a commit, or push a tag, Cloud Platform executes the `pipelines start` command using the build definition file in the GitHub repository, and then commits the resulting [build artifact](/acquia-cloud-platform/features/pipelines/artifacts#pipelines-build-artifact), named `pipelines-build-[BRANCHNAME]`, to your Cloud Platform repository.

Changing your webhook
---------------------

To change the webhook in use by your repository:

Note

You can use the following process to also remove the webhook from your repo. In that case, skip the final step in the following procedure.

1.  Sign in to GitHub.
2.  Go to the following URL:
    
        https://github.com/[your_namespace]/[your_repo]/settings/hooks
    
3.  Delete the webhook associated with your application.
4.  Complete the steps in the earlier connection procedure to reinitialize your repository with the new Acquia application ID and GitHub repository name.

Next step
---------

To operate, Pipelines expects a file in YAML format named `acquia-pipelines.yaml` to exist in the root directory of your code repository. This build definition file has all the information required for Pipelines to perform the build, including any variables required and the instructions used to perform the build.

For information about how to structure this file and what it should contain, see [Creating and managing your build definition file](/acquia-cloud-platform/features/pipelines/yaml).