Skip to content

Instantly share code, notes, and snippets.

@ilgooz
Created February 18, 2015 22:00
Show Gist options
  • Save ilgooz/5d630f49fde1b1394327 to your computer and use it in GitHub Desktop.
Save ilgooz/5d630f49fde1b1394327 to your computer and use it in GitHub Desktop.
FROM golang
MAINTAINER İlker Göktuğ Öztürk <ilkergoktugozturk@gmail.com>
RUN go get ./... && go install bitbucket.org/ilgooz/pdf/app
# Install Java.
RUN \
apt-get update && \
apt-get install -y openjdk-7-jre && \
rm -rf /var/lib/apt/lists/*
ENV JAVA_HOME /usr/lib/jvm/java-7-openjdk-amd64
# Apache FOP
RUN wget http://archive.apache.org/dist/xmlgraphics/fop/binaries/fop-1.1-bin.tar.gz
RUN tar -xzf fop-* && mv fop-1.1 /fop
ADD app /go/src/bitbucket.org/ilgooz/pdf/app
ADD assets /fop/_assets
RUN mkdir /fofiles
VOLUME ["/pdfs"]
ENTRYPOINT /go/bin/app --port 80
EXPOSE 80
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment