Continuous Deployment using Netlify

Netlify allows you to trigger a build, and more importantly a deployment, of a sphinx project based on GitHub commits and pull requests. Thus creating the continuous deployment portion of the pipeline.

Using PR #3 as an example, you can see it has a Details link to the latest netlify build specific to that PR.

_images/pr-build-fail.png

This is a PR that caused a failed build.

Although, since unfortunately we can’t trigger a Netlify build based on a Travis-CI build status we have to add a custom script to the Travis-CI configuration. Since we only want to deploy the site if the project passes the continuous integration process we need to use Netlify’s restore deploy feature on build failures.

Bemerkung

It is possible for their to be a brief window where the failed Netlify build is published before the restore deploy call is run.