21507: removed word wrap on collection owner field Arvados-DCO-1.1-Signed-off-by...
[arvados.git] / services / workbench2 / docker / Dockerfile
index c394d63288725ff7df71490a9e1a99acc198c505..fa4266191aa0c3f8998cc92f879ba4195b6aef4a 100644 (file)
@@ -13,13 +13,17 @@ RUN apt-get update && \
     apt-get clean
 
 RUN /usr/bin/gem install --no-document fpm
-RUN cd /usr/src && git clone git://git.arvados.org/arvados.git && \
-    cd arvados && \
+WORKDIR /usr/src/arvados
+COPY . .
+RUN cd /usr/src/arvados && \
+    test -d cmd/arvados-server || \
+      (echo "ERROR: build context must be an Arvados repository" && false) && \
     GO_VERSION=$(grep 'goversion =' lib/install/deps.go |awk -F'"' '{print $2}') && \
+    ARCH=$(dpkg --print-architecture) && \
     echo $GO_VERSION && \
     cd /usr/src && \
-    wget https://golang.org/dl/go${GO_VERSION}.linux-amd64.tar.gz && \
-    tar xzf go${GO_VERSION}.linux-amd64.tar.gz && \
+    wget https://golang.org/dl/go${GO_VERSION}.linux-${ARCH}.tar.gz && \
+    tar xzf go${GO_VERSION}.linux-${ARCH}.tar.gz && \
     ln -s /usr/src/go/bin/go /usr/local/bin/go-${GO_VERSION} && \
     ln -s /usr/src/go/bin/gofmt /usr/local/bin/gofmt-${GO_VERSION} && \
     ln -s /usr/local/bin/go-${GO_VERSION} /usr/local/bin/go && \