This is a basic blog for KelsonCraft using Hugo and markdown.
To run this, you will need to download the latest version of Hugo and place it in the same folder as the repo.
This needs some submodules for the theme to work, to obtain those use this command: git clone https://github.com/kelson8/kcnet-blog.git --recurse-submodules --recursive
To modify the hello-friend-ng theme, I have copied the index.html, and a few other files from the theme into the layouts folder.
Anything that you want to modify from a theme, recreate the file structure, so for example copy themes/hello-friend-ng/layouts/partials/logo.html to layouts/partials/logo.html and modify it.
You can add posts to this by using this command:
- .\hugo.exe new content
content/posts/post_name.md
To launch this hugo site on Windows, I use Windows Terminal
Command: .\hugo.exe server -D
Launch and bind to local ip: \hugo.exe server -D --bind ip-or-url --baseURL ip-or-url
I now have scripts to run this on Windows run-hugo.bat and Linux run-hugo.sh
To use my docker build script (build-docker-image.sh):
- Change the
BLOG_DIRto the path where you have this repo cloned, and setup theseNGINX_BLOG_DIR,NGINX_BLOG_DATA_DIRinto a spot to place the static files, such as another Nginx server running with Docker.
This site can now be run with docker, use the build-docker-image.sh script to run the build for hugo, and copy the files to the nginx data dir.
- Update this to add some more blog posts
- Setup static site build and test with NGINX or another web server.
- Setup Giscus for comments on the posts with GitHub.
Theme in use: hello-friend-ng
All themes added as submodules:
Look into these themes later:
I have decided to license the content such as the markdown files under the CC BY 4.0 license.
The code and scripts are licensed under the GPLv3 license.