Skip to content

Instantly share code, notes, and snippets.

@wafflespeanut
Created September 20, 2018 06:49
Show Gist options
  • Save wafflespeanut/4d6f5f2bccfcbeba69f14b267d69ad36 to your computer and use it in GitHub Desktop.
Save wafflespeanut/4d6f5f2bccfcbeba69f14b267d69ad36 to your computer and use it in GitHub Desktop.
Dockerfile for Slate
FROM ruby:2.5-alpine
EXPOSE 4567
RUN apk add --update nodejs g++ make git
RUN git clone https://github.com/lord/slate /usr/src/app
WORKDIR /usr/src/app
RUN bundle install
CMD ["bundle", "exec", "middleman", "server", "--watcher-force-polling"]
@wafflespeanut
Copy link
Author

Build image:

docker build -t slate-engine .

Spawn container:

docker run -it --rm -p 4567:4567 \
    -v "$(pwd)/index.md:/usr/src/app/source/index.html.md" \
    -v "$(pwd)/includes:/usr/src/app/source/includes" slate-engine

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment