Auto-Deploy Hugo from Github
GitHub is pretty good with out-of-box options for auto-deploying Hugo or Jekyll sites to GitHub Pages. But say you have your own Linode (or any other) web server - you can still take advantage of GitHub Actions which is a surprisingly versatile piece of CI/CD automation to rival anything you can do on the big cloud providers.
Pre-requisites
- You have your Hugo site checked in to a GitHub repository
- You have a Linode (or other) web server with SSH access
- You have a good
.gitignoresetup so that the Hugo build files are not checked in to your repository a good Hugo example of .gitignore here
An example .gitignore that should be checked in to the root of your project: