github.com/gust1n/deis@v0.13.1-0.20141009230754-43ff4d95947b/database/Dockerfile (about) 1 FROM ubuntu:14.04 2 3 ENV DEBIAN_FRONTEND noninteractive 4 5 # install common packages 6 RUN apt-get update && apt-get install -y curl 7 8 # install etcdctl 9 RUN curl -sSL -o /usr/local/bin/etcdctl https://s3-us-west-2.amazonaws.com/opdemand/etcdctl-v0.4.6 \ 10 && chmod +x /usr/local/bin/etcdctl 11 12 # install confd 13 RUN curl -sSL -o /usr/local/bin/confd https://s3-us-west-2.amazonaws.com/opdemand/confd-v0.5.0-json \ 14 && chmod +x /usr/local/bin/confd 15 16 # install postgresql 9.3 from postgresql.org repository as well as requirements for building wal-e 17 RUN echo "deb http://apt.postgresql.org/pub/repos/apt/ trusty-pgdg main" > /etc/apt/sources.list.d/pgdg.list 18 RUN curl -sk https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add - 19 RUN apt-get update && apt-get install -yq \ 20 curl \ 21 daemontools \ 22 file \ 23 gcc \ 24 git \ 25 libxml2-dev \ 26 libxslt1-dev \ 27 lzop \ 28 postgresql-9.3 \ 29 pv \ 30 python-dev 31 32 RUN /etc/init.d/postgresql stop 33 34 # install pip 35 RUN curl -sSL https://raw.githubusercontent.com/pypa/pip/1.5.6/contrib/get-pip.py | python - 36 37 # install wal-e 38 WORKDIR /tmp 39 RUN git clone https://github.com/wal-e/wal-e.git 40 WORKDIR /tmp/wal-e 41 RUN git checkout c6f0d02 42 RUN pip install . 43 RUN mkdir -p /etc/wal-e.d/env 44 RUN chown -R root:postgres /etc/wal-e.d 45 46 # define the execution environment 47 WORKDIR /app 48 CMD ["/app/bin/boot"] 49 EXPOSE 5432 50 ADD . /app