VuePress website hosted on GitHub Pages
I started Jekyll project first to host on Github Pages but GitHub released new GitHub Actions integrations on July 27th, 2022 so I moved to VuePress.
You can use GitHub Actions to build any static website and GitHub Pages to host it quick and for free.
GitHub Actions and VuePress documentation is great so I list the sequence of steps briefly.
Static website setup instructions
- Register (sub)domain and set DNS CNAME record to
- Create VuePress site and make a repository
- Host the repository on GitHub
- Add new workflow at GitHub Actions tab according to VuePress Guide
- If you use sample config and custom domain add
fqdnparameter in the last
# please check out the docs of the workflow for more details # @see https://github.com/crazy-max/ghaction-github-pages - name: Deploy to GitHub Pages uses: crazy-max/ghaction-github-pages@v2 with: # deploy to gh-pages branch target_branch: gh-pages # deploy the default output dir of VuePress build_dir: docs/.vuepress/dist # domain name to set in CNAME file fqdn: notes.arapov.net
- GitHub action will build and push updated static site to
gh-pagesbranch at any commit
- Check your repository Settings -> Pages page and select
gh-pagesbranch to deploy from
- GitHub Pages Deployment — VuePress manual
- A GitHub Action to deploy to GitHub Pages by CrazyMax
- Quickstart for GitHub Pages — GitHub guide