This Dockerfile was created to host my static Hugo website over at CFultz.pro to be a proof of concept that I could do it.
I have attached my deploy.sh that I used as well to create my site, build the image and deploy it to my local Docker environment.
There are three flavors: lighttpd, apache/httpd, and nginx
Note: you will need to have Docker and Hugo already installed
In your Hugo website directory, process the following:
git clone https://github.com/cfultz/hugo-webserver-docker.git
chmod +x deploy.sh
./deploy.sh
Note: you will need to have Docker and Hugo already installed
This will pull the latest pre-compiled container from Docker Hub In your Hugo website directory, process the following:
rm -rf /home/user/hugo/public && docker container stop hugo
hugo && docker run -it --restart=always -d -p 80:80 --name hugo-webserver cfultz/hugo-webserver
This work by Caleb Fultz aka cfultz is licensed under the Creative Commons CC0 1.0 License. All tools and other works utilized are licensed under their respective licenses and copyrights.
Content type
Image
Digest
sha256:f7c61ad7d…
Size
5 MB
Last updated
almost 3 years ago
docker pull cfultz/hugo-webserver