Skip to Content

Deploy from Git

Deploy a repository from GitHub, GitLab, Bitbucket, Gitea or any Git server, and redeploy on every push.

Point an app at a repository: Deplo builds it, and every push to the branch deploys again. Connect your Git host once per team, in Settings -> Git. It needs Manage Git connections.

Connect your Git host

Settings -> Git -> Connect -> GitHub, or Connect GitHub in the wizard.

Pick Personal account, or Organization and type its name as in github.com/acme. Connect again for each other account or organization.

On GitHub, create the App and install it on All repositories or Only select repositories.

Manage, in the App's menu on Settings -> Git, changes which repositories it sees.

Pending permissions

When the App lacks a permission, Deplo shows Deplo is missing access on GitHub. Update on GitHub opens the page to grant it, but GitHub keeps the change pending until someone accepts it on each installation. Accept it there too.

What the token needs

ProviderScopeFor
GitLabread_repositoryClone your code
GitLabapiList your projects, deploy on push
BitbucketRepositories: ReadList and clone your repositories
BitbucketWebhooks: Read and writeDeploy on push
Gitearead:repositoryList and clone your repositories
Giteawrite:repositoryDeploy on push

Deploy a repository

Pick the source

Add New -> Application, then GitHub or Git. On Git, pick the Provider, or Repository URL.

The Git source step

Pick the repository and branch

From the list, or paste a URL like https://git.example.com/acme/site.git and type the Production branch.

Check the settings and deploy

The wizard shows the App name, the framework and the Build command. A GitHub repository is read ahead; any other shows Detected at build time. Advanced holds the server, variables and Root directory. Click Deploy.

Pull request previews need GitHub. See Pull request previews.

Change the source later

Settings -> Deployments, Source card: change the repository, the branch, the Root directory or the source type. The app keeps its domains, variables and volumes. Saving does not deploy: click Redeploy.

Settings -> Deployments: the source of a running app

Good to know

  • A Dockerfile or a Compose file in the repository is used. See Build settings.
  • Two apps can track two branches of the same repository, like main and staging.
  • A new repository on a connected host shows a New repository detected card on the Overview. Import opens the wizard with it picked.

Something wrong? See Deploys and builds.

Did this page help you?

On this page