Deploy Builds and Deploy Previews, as their names imply, are used for readying your site for deployment. When you add a site to Gatsby Cloud, you will find them under the Deploys tab of the Site Overview page.
Deploy Builds
A Deploy Build is a build of your site's production branch, i.e., the repository branch you select when creating a site. Deploy builds are suitable for hosting on the internet. If you connect your site to a hosting service (e.g. Netlify), the site will automatically deploy after a Deploy Build completes.
How Deploy Builds are Triggered
A Deploy Build may be triggered when any of following events occur:
- a new Gatsby Cloud site is created
- a Git commit to the production branch (e.g. pushing a new code or merging a pull request)
- the Trigger Build button in the Gatsby Cloud user interface is clicked
- a POST request to the Build Webhook
- an update from a connected content management system (configuration dependent)
Deploy Previews
A Deploy Preview is a build of a non production branch of your site. Deploy Previews are intended to show the impact of potential code changes before merging those changes into your production branch.
How Deploy Previews are Triggered
A Deploy Preview build will be triggered when any of the following events occur:
- a pull request (PR) is opened against the site's production branch
- a new commit is pushed to the PR branch
- the Trigger Build button in the Gatsby Cloud user interface is clicked