How to use Git with Plesk

This article describes how to configure Plesk's integration with the Git version control system.

Plesk is no longer included with new A2 Hosting plans, but it is still available on legacy Managed WordPress accounts. You can install Plesk manually on unmanaged VPS and Dedicated servers.

Setting up a remote repository

In Plesk, you can configure a remote Git repository and pull files to your site. To do this, follow these steps:

  1. Log in to Plesk.
    If you do not know how to log in to your Plesk account, please see this article.
  2. In the left sidebar, click Websites & Domains:

    Plesk - Sidebar - Websites and Domains

  3. Locate the domain you want to configure, and then click the Git icon:

    Plesk - Git icon

  4. On the Add Git Repository page, confirm the Remote Git hosting like GitHub or BitBucket option is selected:

    Plesk - Git - Add remote repository

  5. In the Remote Git repository text box, type the URL where the remote repository is hosted:

    Plesk - Git - Add remote repository configuration

    Plesk supports HTTPS and SSH protocols for Git.
  6. To select the deployment mode, click automatically deployed, select the mode you want, and then click Ok.
  7. To select the deployment directory on your site, click /httpdocs/, select the local directory you want to use, and then click Ok.
  8. Click OK. Plesk clones the remote repository into the local directory you specified in step 7.

    To pull updates from the remote repository, click Pull Updates.

Creating a local repository

In Plesk, you can create a local Git repository. To do this, follow these steps:

  1. Log in to Plesk.
    If you do not know how to log in to your Plesk account, please see this article.
  2. In the left sidebar, click Websites & Domains:

    Plesk - Sidebar - Websites and Domains

  3. Locate the domain you want to configure, and then click the Git icon:

    Plesk - Git icon

  4. Click Add Repository.
  5. Select Local repository on your workstation:

    Plesk - Git - Add local repository

  6. In the Git Repository in Plesk text box, type the name of the new repository:

    Plesk - Git - Add local repository configuration

  7. To select the deployment mode, click automatically deployed, select the mode you want, and then click Ok.
  8. To select the deployment directory on your site, click /httpdocs/, select the local directory you want to use, and then click Ok.
  9. Click OK. Plesk creates the local repository.

Editing repository settings

To edit the settings of an existing repository in Plesk, follow these steps:

  1. Log in to Plesk.
    If you do not know how to log in to your Plesk account, please see this article.
  2. In the left sidebar, click Websites & Domains:

    Plesk - Sidebar - Websites and Domains

  3. Locate the domain you want to configure, and then click the Git icon:

    Plesk - Git icon

  4. Locate the Git repository you want to edit, and then click Repository Settings:

    Plesk - Git - Repository settings

  5. On the settings page, make the changes you want, and then click OK. Plesk updates the settings.

More Information

Did you find this article helpful? Then you'll love our support. Experience the A2 Hosting difference today and get a pre-secured, pre-optimized website. Check out our web hosting plans today.

We use cookies to personalize the website for you and to analyze the use of our website. You consent to this by clicking on "I consent" or by continuing your use of this website. Further information about cookies can be found in our Privacy Policy.