-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dockerfile
36 lines (29 loc) · 934 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
ARG JEKYLL_VERSION=3.8
FROM jekyll/jekyll:${JEKYLL_VERSION}
# Set Jekyll configuration variables
ENV JEKYLL_UID=1000
ENV JEKYLL_GID=1000
ENV JEKYLL_DEBUG=""
ENV VERBOSE=""
ENV FORCE_POLLING=""
# Set workdir to where all install should take place
COPY ./ /srv/jekyll/
RUN chown -R jekyll /srv/jekyll/
WORKDIR /srv/jekyll
# Install latest changes for theme, from Gemfile
RUN [ ! -f "Gemfile.lock" ] || { \
cat Gemfile.lock && \
echo "Remove old Gemfile.lock" && \
rm -f Gemfile.lock ; }
# Hold back the Bundler version since latest version has dropped support for
# this old Ruby version
RUN gem install bundler -v 2.4.22
# Run bundle install separately, seems to hang sometimes when using one RUN
RUN bundle install && \
bundle info --path just-the-docs
# Build HTML pages from markdown files
RUN pwd && ls -la && jekyll --version && \
jekyll build --trace && \
pwd && ls -la
# Expose a port
EXPOSE 4000