Skip to content

Instantly share code, notes, and snippets.

@gythialy
Last active February 26, 2023 12:35
Show Gist options
  • Save gythialy/10b65eb8286da6ebfee4583f4c83acb9 to your computer and use it in GitHub Desktop.
Save gythialy/10b65eb8286da6ebfee4583f4c83acb9 to your computer and use it in GitHub Desktop.
build gitbook docker image
FROM node:12.11.1-slim
RUN apt-get update && \
apt-get install -y --no-install-recommends build-essential git procps openssh-client git bzip2 graphviz calibre fonts-noto fonts-noto-cjk locales-all && \
rm -rf /var/lib/apt/lists/*
RUN npm config set unsafe-perm true && \
npm install gitbook-cli svgexport -g
WORKDIR /books
VOLUME [/books]
❯ docker run -it --rm -v $(pwd)/kubernetes-handbook:/books gythialy/gitbook-builder:latest bash
gitbook pdf . $(BOOK_NAME).pdf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment