Skip to content

Commit

Permalink
feat: add Dockerfile
Browse files Browse the repository at this point in the history
Signed-off-by: G.J.LEE <[email protected]>
  • Loading branch information
G.J.LEE committed May 8, 2023
1 parent 5fa7473 commit c156e48
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
FROM klakegg/hugo:0.107.0-ext-pandoc AS build

RUN apk add --update \
wget

WORKDIR /site
COPY ./ /site

RUN apk add --no-cache \
git && \
git submodule update --init --recursive --depth 1


ARG HUGO_VERSION="0.107.0"

RUN hugo --minify --environment production -t hugo-book

FROM nginx:alpine
COPY --from=build /site/public /usr/share/nginx/html/

CMD ["/bin/sh", "-c", "exec nginx -g 'daemon off;'"]

EXPOSE 80
WORKDIR /usr/share/nginx/html

0 comments on commit c156e48

Please sign in to comment.