Last active
August 29, 2015 14:13
-
-
Save thiago/11954edbd7a24ec59244 to your computer and use it in GitHub Desktop.
A tsuru platform to apache zookeeper
This file contains hidden or 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
# DOCKER-VERSION 1.0.1 | |
# VERSION 0.5 | |
FROM ubuntu:14.04 | |
RUN apt-get update && apt-get install -y openjdk-7-jre-headless wget | |
RUN wget -q -O - http://apache.mirrors.pair.com/zookeeper/zookeeper-3.4.6/zookeeper-3.4.6.tar.gz | tar -xzf - -C /opt \ | |
&& mv /opt/zookeeper-3.4.6 /opt/zookeeper \ | |
&& cp /opt/zookeeper/conf/zoo_sample.cfg /opt/zookeeper/conf/zoo.cfg | |
ENV JAVA_HOME /usr/lib/jvm/java-7-openjdk-amd64 | |
RUN apt-get install wget -y --force-yes | |
RUN wget http://github.com/tsuru/basebuilder/tarball/master -O basebuilder.tar.gz --no-check-certificate | |
RUN mkdir -p /var/lib/tsuru | |
RUN tar -xvf basebuilder.tar.gz -C /var/lib/tsuru --strip 1 | |
RUN cp /var/lib/tsuru/base/start /var/lib/tsuru | |
RUN cp /var/lib/tsuru/base/deploy /var/lib/tsuru | |
RUN /var/lib/tsuru/base/install |
This file contains hidden or 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
#!/bin/bash -l | |
echo "Starting the Zookeeper application..." | |
SOURCE_DIR=/var/lib/tsuru | |
source ${SOURCE_DIR}/config | |
if [ -f ${CURRENT_DIR}/zoo.cfg ]; then | |
cp ${CURRENT_DIR}/zoo.cfg /opt/zookeeper/conf/zoo.cfg | |
fi | |
# Call the default start script | |
source ${SOURCE_DIR}/base/start |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment