Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
ZKSandbox's Dockerfile
FROM java:8-jdk
MAINTAINER Jumper Chen <jumperchen@potix.com>
ENV JAVA_HOME /usr/lib/jvm/java-8-openjdk-amd64
# Config to get to install git, maven, and tomcat7
RUN apt-get update && apt-get install -y --force-yes git maven tomcat7
VOLUME /zksandbox
# copy your zksandbox (depends on where the Dockerfile located) folder
# into the container's folder /zksandbox
COPY zksandbox /zksandbox
WORKDIR /zksandbox
RUN mvn clean package
ENV CATALINA_HOME /usr/share/tomcat7
ENV PATH $PATH:$CATALINA_HOME/bin:$JAVA_HOME/bin
# Configure Tomcat 7 directories
RUN ln -s /var/lib/tomcat7/common $CATALINA_HOME/common && \
ln -s /var/lib/tomcat7/server $CATALINA_HOME/server && \
ln -s /var/lib/tomcat7/shared $CATALINA_HOME/shared && \
ln -s /etc/tomcat7 $CATALINA_HOME/conf && \
mkdir $CATALINA_HOME/temp && \
mkdir $CATALINA_HOME/webapps && \
ln -s /zksandbox/debug/zksandbox $CATALINA_HOME/webapps/zksandbox
CMD ["catalina.sh", "run"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.