Created
January 18, 2018 15:45
-
-
Save tgvaughan/b59ed136e4d4f23d69267cce865481ac to your computer and use it in GitHub Desktop.
Dockerfile for building the TTB website
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM debian:latest | |
RUN apt-get update | |
# Essential build environment | |
RUN apt-get install -y build-essential git | |
# Install ruby and bundler | |
RUN apt-get install -y ruby ruby-dev | |
RUN gem install bundler | |
# Install LaTeX | |
RUN apt-get install -y texlive | |
RUN apt-get install -y texlive-latex-extra | |
RUN apt-get install -y biber | |
# Configure locale (strange things happen otherwise) | |
ENV LC_ALL "C.UTF-8" | |
ENV LANG "C.UTF-8" | |
WORKDIR /ttb | |
# Construct script for building site | |
RUN cat <<EOF >/ttb/build_script.sh | |
#!/bin/bash | |
cd /ttb | |
rm -rf blotter | |
git clone --depth 1 https://github.com/taming-the-beast/blotter.git | |
cd /ttb/blotter | |
bundle install | |
ruby _scripts/update-and-preprocess.rb | |
if bundle exec jekyll build; then | |
rm -rf /ttb/site | |
cp -R /ttb/blotter/_site /ttb/site | |
fi | |
EOF |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment