aboutsummaryrefslogtreecommitdiffstats
path: root/docker/barometer-dma
diff options
context:
space:
mode:
authorToshiaki Takahashi <takahashi.tsc@ncos.nec.co.jp>2018-09-06 10:35:27 +0000
committerToshiaki Takahashi <takahashi.tsc@ncos.nec.co.jp>2018-09-07 06:03:21 +0000
commit7d1819f9aa56a3db1b1354b3dbb29f69eb67aaa3 (patch)
tree02adb5f463821acfb66665bcbdc12dd140f6b428 /docker/barometer-dma
parentdfaf48cb7674f84c67b89ed495660f0d98c7ca7c (diff)
docker: Add Dockerfile of DMA localagent
Change-Id: I2e12ee574cc0b1fd5de178b576590ae78ff533c6 Signed-off-by: Toshiaki Takahashi <takahashi.tsc@ncos.nec.co.jp>
Diffstat (limited to 'docker/barometer-dma')
-rw-r--r--docker/barometer-dma/Dockerfile25
1 files changed, 25 insertions, 0 deletions
diff --git a/docker/barometer-dma/Dockerfile b/docker/barometer-dma/Dockerfile
new file mode 100644
index 00000000..afe7c3f3
--- /dev/null
+++ b/docker/barometer-dma/Dockerfile
@@ -0,0 +1,25 @@
+FROM centos:7
+
+# install prerequisites
+RUN yum update -y &&\
+ yum install -y which sudo git libvirt-devel && \
+ rpm --import https://mirror.go-repo.io/centos/RPM-GPG-KEY-GO-REPO && \
+ curl -s https://mirror.go-repo.io/centos/go-repo.repo | tee /etc/yum.repos.d/go-repo.repo && \
+ yum install -y golang
+
+# set environment variables
+# need to change when we move to barometer
+ENV DOCKER y
+ENV repos_dir /root/go/src/github.com/distributed-monitoring/agent
+
+# copy repo code and
+# COPY . ${repos_dir}
+WORKDIR ${repos_dir}
+RUN git clone https://gerrit.opnfv.org/gerrit/barometer && \
+ mv barometer/src/dma/* ./
+RUN go build ./cmd/server && \
+ go build ./cmd/threshold && \
+ go build ./cmd/infofetch
+
+RUN cp server threshold infofetch /
+WORKDIR /