Files
jekyll-serve/Dockerfile
Ester Daniel Ytterbrink 087e0f0870 Update Ruby-version
I needed Jekyll running with a newer Ruby version to get the Gems right for the server I am running the site on.
2026-03-04 10:36:42 +01:00

28 lines
710 B
Docker

FROM ruby:4.0.1-slim-trixie as jekyll
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential \
git \
&& rm -rf /var/lib/apt/lists/*
# used in the jekyll-server image, which is FROM this image
COPY docker-entrypoint.sh /usr/local/bin/
RUN gem update --system && gem install jekyll && gem cleanup
EXPOSE 4000
WORKDIR /site
ENTRYPOINT [ "jekyll" ]
CMD [ "--help" ]
# build from the image we just built with different metadata
FROM jekyll as jekyll-serve
# on every container start, check if Gemfile exists and warn if it's missing
ENTRYPOINT [ "docker-entrypoint.sh" ]
CMD [ "bundle", "exec", "jekyll", "serve", "--force_polling", "-H", "0.0.0.0", "-P", "4000" ]