You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Dockerfile 770B

123456789101112131415161718192021222324252627
  1. ##
  2. ## Step 1 - add content and build with Hugo
  3. ##
  4. FROM debian:stretch as hugo
  5. RUN apt-get -qq update \
  6. && DEBIAN_FRONTEND=noninteractive apt-get -qq install -y --no-install-recommends python-pygments git ca-certificates asciidoctor \
  7. && rm -rf /var/lib/apt/lists/*
  8. ENV HUGO_VERSION 0.53
  9. ENV HUGO_BINARY hugo_${HUGO_VERSION}_Linux-64bit.deb
  10. ADD https://github.com/spf13/hugo/releases/download/v${HUGO_VERSION}/${HUGO_BINARY} /tmp/hugo.deb
  11. RUN dpkg -i /tmp/hugo.deb \
  12. && rm /tmp/hugo.deb
  13. ADD . /tmp/site
  14. RUN hugo -b https://kb.chameth.com/ -v -s /tmp/site -d /tmp/hugo && \
  15. cp /tmp/hugo/index.xml /tmp/hugo/feed.xml
  16. ##
  17. ## Step 3 - host!
  18. ##
  19. FROM nginx:mainline-alpine AS nginx
  20. COPY --from=hugo /tmp/site /usr/share/nginx/html
  21. ADD nginx.conf /etc/nginx/nginx.conf