You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficcontrol.apache.org by so...@apache.org on 2017/03/10 15:20:21 UTC

[07/14] incubator-trafficcontrol git commit: convert Dockerfile for TP build

convert Dockerfile for TP build


Project: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/commit/ba193b8f
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/tree/ba193b8f
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/diff/ba193b8f

Branch: refs/heads/master
Commit: ba193b8f2c28846d31d66454868ddfd17862df0f
Parents: 544516e
Author: Dan Kirkwood <da...@gmail.com>
Authored: Wed Jan 25 20:35:09 2017 -0700
Committer: Phil Sorber <so...@apache.org>
Committed: Fri Mar 10 08:18:25 2017 -0700

----------------------------------------------------------------------
 .../docker/build/Dockerfile-traffic_portal       | 19 +++++++++----------
 1 file changed, 9 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/blob/ba193b8f/infrastructure/docker/build/Dockerfile-traffic_portal
----------------------------------------------------------------------
diff --git a/infrastructure/docker/build/Dockerfile-traffic_portal b/infrastructure/docker/build/Dockerfile-traffic_portal
index 7d535f5..96c69dc 100644
--- a/infrastructure/docker/build/Dockerfile-traffic_portal
+++ b/infrastructure/docker/build/Dockerfile-traffic_portal
@@ -18,17 +18,17 @@ FROM centos:7
 
 MAINTAINER Dan Kirkwood
 
+# top level of trafficcontrol directory must be mounted as a volume:
+# docker run --volume /trafficcontrol:$(pwd) ...
+VOLUME /trafficcontrol
+
+### Common for all sub-component builds
 RUN	yum -y install \
 		epel-release \
 		git \
 		rpm-build && \
 	yum -y clean all
 
-ENV GITREPO https://github.com/apache/incubator-trafficcontrol
-ENV BRANCH master
-
-WORKDIR /repo
-
 # traffic_portal specific
 RUN	yum -y install \
 		gcc \
@@ -47,10 +47,9 @@ RUN	echo '{ "allow_root": true }' > /root/.bowerrc
 
 ###
 
-VOLUME ./artifacts:/artifacts
-
-ADD run-build.sh .
-
-CMD ./run-build.sh traffic_portal 2>&1 | tee /artifacts/build-traffic_portal.log
+WORKDIR /trafficcontrol
+CMD mkdir -p dist && \
+	./build/build.sh traffic_portal 2>&1 | \
+	tee ./dist/build-traffic_portal.log
 
 # vi:syntax=Dockerfile