nikola
Nikola is one of static site generator written in python3.
- It supports some input formats include Markdown.
- Theme is written in Mako or Jinja2. The user can use any existing theme or can create your own theme inherits from existing one.
- The user can specify deployment procedure and run it.
- Especially for Github pages, you can build the site, commit the changes, and push the output to github with one command.
As described in the footer of this page, I use it now.
This is a sample Dockerfile. The docker image will become about 353MB.
FROM alpine:latest
ARG version=8.1.3
ARG PIP_INDEX_URL
ARG PIP_TRUSTED_HOST
RUN apk --update --no-cache add py3-pip git bash openssh \
gcc musl-dev python3-dev libxml2-dev libxslt-dev libjpeg-turbo-dev \
&& rm -rf /var/cache/apk/* \
&& pip3 install nikola==${version} jinja2 ghp-import2 \
&& mkdir /tmp/nikola \
&& adduser -H -D docker
VOLUME ["/tmp/nikola"]
EXPOSE 80
USER "docker"
WORKDIR "/tmp/nikola"
CMD ["/bin/bash"]
The build command will be like shown below:
docker build --build-arg version=8.1.3 --build-arg PIP_TRUSTED_HOST=192.168.xxx.xxx --build-arg PIP_INDEX_URL=http://192.168.xxx.xxx:3141/root/pypi -t nikola:alpine -f Dockerfile.alpine .