diff --git a/.gitignore b/.gitignore index f76353492..b35e97f66 100644 --- a/.gitignore +++ b/.gitignore @@ -52,5 +52,3 @@ experimental/_integration/_integration *sublime-project *sublime-workspace *npm-debug.log -backend/scope-app -backend/scope-probe diff --git a/Makefile b/Makefile index 4372f3696..7106fb37c 100644 --- a/Makefile +++ b/Makefile @@ -77,11 +77,9 @@ $(SCOPE_UI_BUILD_EXPORT): client/Dockerfile client/package.json client/webpack.l docker build -t $(SCOPE_UI_BUILD_IMAGE) client docker save $(SCOPE_UI_BUILD_IMAGE):latest > $@ -# backend is an alternate Docker-based method to produce APP_EXE and PROBE_EXE backend: docker build -t $(SCOPE_BACKEND_BUILD_IMAGE) backend - docker run -ti -v $(shell pwd)/app:/mount $(SCOPE_BACKEND_BUILD_IMAGE) cp /go/bin/scope-app /mount - docker run -ti -v $(shell pwd)/probe:/mount $(SCOPE_BACKEND_BUILD_IMAGE) cp /go/bin/scope-probe /mount + docker run -ti -v $(shell pwd):/go/src/github.com/weaveworks/scope $(SCOPE_BACKEND_BUILD_IMAGE) /build.bash clean: go clean ./... diff --git a/backend/Dockerfile b/backend/Dockerfile index 3d4fe97e7..dc2716f1e 100644 --- a/backend/Dockerfile +++ b/backend/Dockerfile @@ -1,5 +1,4 @@ FROM golang:1.5.1 RUN apt-get update && apt-get install -y libpcap-dev COPY build.bash / -RUN /build.bash diff --git a/backend/build.bash b/backend/build.bash index 91c9f5d78..134cf557b 100755 --- a/backend/build.bash +++ b/backend/build.bash @@ -1,12 +1,12 @@ #!/bin/bash -mkdir -p /go/src/github.com/weaveworks -cd /go/src/github.com/weaveworks -git clone https://github.com/weaveworks/scope -cd scope -make deps -SUDO= make app/scope-app -mv app/scope-app $GOPATH/bin -SUDO= make probe/scope-probe -mv probe/scope-probe $GOPATH/bin +set -x + +# Mount the scope repo: +# -v $(pwd):/go/src/github.com/weaveworks/scope + +cd /go/src/github.com/weaveworks/scope +make deps +make app/scope-app +make probe/scope-probe