Use this repository to test Docker images such as:
- https://github.com/gohugoio/hugo/pkgs/container/hugo (official)
- https://hub.docker.com/r/veriphor/hugo
These live sites were built with a veriphor/hugo container:
This site is designed to test these features and capabilities:
- Including content from a Hugo module
- Transpiling Sass to CSS using Dart Sass
- Vendor prefixing of CSS rules using the postcss, postcss-cli, and autoprefixer Node.js packages
- Processing CSS files using the tailwindcss and @tailwindcss-cli Node.js packages
- Encoding images to the WebP format to verify that we're using Hugo's extended edition
- Including a content file named hugö.md to verify that the Git
core.quotepath
setting isfalse
1 - Rendering of AsciiDoc content
- Rendering of Pandoc content
- Rendering of reStructuredText content
- Enabling site search with Pagefind
To test items 7-10 you must use the -e extra
command line flag.
Clone the repository:
git clone https://github.com/jmooring/hugo-docker-test
cd hugo-docker-test
Then see the Hugo documentation for the relevant operating system:
Note that the official Docker image does not support items 7-10 above.
Clone the repository and install the Node.js packages:
git clone https://github.com/jmooring/hugo-docker-test
cd hugo-docker-test
npm ci
The commands below assume you have aliased dhugo
to:
docker run --rm -v .:/project -v $HOME/.cache/hugo_cache:/cache -u $(id -u):$(id -g) --network host veriphor/hugo hugo
Build the site without Pagefind:
dhugo server -e extra
Build the site using a local installation of the Pagefind executable:
dhugo -e extra && ./pagefind --site public --serve
Build the site using the Pagefind executable within the Docker image:
docker run --rm -v .:/project -v $HOME/.cache/hugo_cache:/cache -u $(id -u):$(id -g) --network host veriphor/hugo bash -c "hugo -e extra && pagefind --site public --serve"
Footnotes
-
See issue #9810. Git's
core.quotepath
setting isfalse
if/other/hugö
has a non-zero "last modified" date. ↩