> ## Documentation Index
> Fetch the complete documentation index at: https://developer.upsun.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Source integrations

> See how to maintain your code in a third-party repository that's linked to your Upsun Cloud project.

A source integration links your Upsun Cloud project to a third-party Git repository (GitHub, GitLab, or Bitbucket),
making that repository the source of truth. Upsun Cloud mirrors the repository and manages environments
based on your repository's branch and pull request activity. For example:

* When you open a pull request, Upsun Cloud spins up an identical preview environment that reflects the contents of the pull request.
* After you push code to your external repository, Upsun Cloud mirrors the updated code and redeploys the affected environments.

This integration enables you to keep your code and CI/CD workflows on your Git provider of choice and use Upsun Cloud for deployment.

<Warning>
  If you connect an external repo to Upsun Cloud, do not push code directly to Upsun Cloud: push to your external repository.

  Upsun Cloud overwrites any changes pushed to it directly in order to mirror the external repository.
</Warning>

<CardGroup cols={2}>
  <Card title="Bitbucket" icon="git-branch" href="/docs/integrations/source/bitbucket">
    Manage your Upsun Cloud environments directly from your Bitbucket repository.
  </Card>

  <Card title="GitHub" icon="github" href="/docs/integrations/source/github">
    Manage your Upsun Cloud environments directly from your GitHub repository.
  </Card>

  <Card title="GitLab" icon="gitlab" href="/docs/integrations/source/gitlab">
    Manage your Upsun Cloud environments directly from your GitLab repository.
  </Card>

  <Card title="Troubleshoot" icon="wrench" href="/docs/integrations/source/troubleshoot">
    Resolve access rights issues with integrated repositories.
  </Card>
</CardGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.