Permalink
Browse files

Dockerfile: Build rebar 2.5.0 from source

  • Loading branch information...
rnewson committed Jul 19, 2014
1 parent afe4671 commit 5c94e815e60dc53db735243e0d532b03bbe319c3
Showing with 15 additions and 3 deletions.
  1. +15 −3 Dockerfile
View
@@ -5,14 +5,26 @@ ENV DEBIAN_FRONTEND noninteractive
# Install prereqs
RUN echo "deb http://http.debian.net/debian wheezy-backports main" >> /etc/apt/sources.list
RUN apt-get -qq update
-RUN apt-get -y install build-essential git libmozjs185-dev libicu-dev erlang-nox rebar
+RUN apt-get -y install build-essential git libmozjs185-dev libicu-dev erlang-nox erlang-dev python wget
-# Set up user for the build
+# Set up user for the builds
RUN useradd -m couchdb
+
+# Build rebar
USER couchdb
+WORKDIR /home/couchdb
+
+RUN wget https://github.com/rebar/rebar/archive/2.5.0.tar.gz
+RUN tar xzf 2.5.0.tar.gz
+WORKDIR /home/couchdb/rebar-2.5.0
+RUN ./bootstrap
+USER root
+RUN cp rebar /usr/local/bin/
-# Get the source
+# Build couchdb
+USER couchdb
WORKDIR /home/couchdb
+
RUN git clone https://git-wip-us.apache.org/repos/asf/couchdb.git
WORKDIR /home/couchdb/couchdb

0 comments on commit 5c94e81

Please sign in to comment.