Hugo builds blazing-fast static HTML. On a VPS it fits blogs and landings with no PHP or database.
Steps
Install Hugo (distro package; use the official .deb for newest):
sudo apt updatesudo apt install -y hugohugo versionCreate the site and a sample post:
mkdir -p ~/sites && cd ~/siteshugo new site mysite && cd mysitehugo new content posts/hello.mdhugoPublish public/ with Nginx (adjust root/server_name):
sudo mkdir -p /var/www/mysitesudo rsync -a ~/sites/mysite/public/ /var/www/mysite/sudo tee /etc/nginx/sites-available/mysite >/dev/null <<'EOF'server { listen 80; server_name example.com; root /var/www/mysite; index index.html;}EOFsudo ln -sf /etc/nginx/sites-available/mysite /etc/nginx/sites-enabled/mysitesudo nginx -t && sudo systemctl reload nginxAfter content edits, rebuild and sync:
cd ~/sites/mysite && hugosudo rsync -a ~/sites/mysite/public/ /var/www/mysite/
Tips
- Add a theme under
themes/and enable it inhugo.toml. - Add HTTPS with Certbot once DNS points at the VPS.
ext step
Serve your static site on a clean VPS: Deploy your Cloud VPS.