-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
40 lines (29 loc) · 684 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
ARG JEKYLL_BASEURL=''
####################################
FROM alpine:3.7 as builder
ENV LANGUAGE en_US.UTF-8
ENV LANG en_US.UTF-8
ENV LC_ALL en_US.UTF-8
ENV BUILD_PACKAGES \
ruby \
ruby-dev \
ruby-rdoc \
ruby-irb \
gcc \
make \
libc-dev \
libffi-dev \
build-base
RUN apk add --no-cache $BUILD_PACKAGES \
&& gem install bundle
WORKDIR /jekyll
ADD . /jekyll
RUN bundle install
ARG JEKYLL_BASEURL
RUN jekyll build --baseurl $JEKYLL_BASEURL
####################################
FROM nginx:alpine
ARG JEKYLL_BASEURL
COPY --from=builder /jekyll/_site /usr/share/nginx/html/$JEKYLL_BASEURL
COPY nginx.conf /etc/nginx/nginx.conf
EXPOSE 80