You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mnemonic.apache.org by ga...@apache.org on 2017/10/12 04:54:56 UTC

incubator-mnemonic git commit: MNEMONIC-385: Ubuntu dockerfile doesn't work behind http proxy

Repository: incubator-mnemonic
Updated Branches:
  refs/heads/master 67f074a20 -> 68edd0815


MNEMONIC-385: Ubuntu dockerfile doesn't work behind http proxy


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

Branch: refs/heads/master
Commit: 68edd0815a80586f6d3f2db8d17bbc6ec2a100f7
Parents: 67f074a
Author: Wang, Gang(Gary) <ga...@intel.com>
Authored: Wed Oct 11 21:54:04 2017 -0700
Committer: Wang, Gang(Gary) <ga...@intel.com>
Committed: Wed Oct 11 21:54:04 2017 -0700

----------------------------------------------------------------------
 docker/docker-Ubuntu/Dockerfile | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-mnemonic/blob/68edd081/docker/docker-Ubuntu/Dockerfile
----------------------------------------------------------------------
diff --git a/docker/docker-Ubuntu/Dockerfile b/docker/docker-Ubuntu/Dockerfile
index 112a9f7..984ae3e 100644
--- a/docker/docker-Ubuntu/Dockerfile
+++ b/docker/docker-Ubuntu/Dockerfile
@@ -46,12 +46,13 @@ RUN cd /ws && git clone https://github.com/NonVolatileComputing/pmalloc.git && \
 RUN cd /ws && git clone https://github.com/pmem/nvml.git && \
     cd nvml && git checkout 630862e82f && make && make install
 
-RUN echo export MAVEN_OPTS="\" $([[ \"x\" != \"x${proxy_host}\" ]] && echo -DproxySet=\\\"true\\\" -DproxyHost=${proxy_host} -DproxyPort=${proxy_port}) \"" \
-    > /etc/profile.d/mvn.sh && chmod +x /etc/profile.d/mvn.sh
-    
-RUN /bin/bash -c "source /etc/profile.d/mvn.sh"
-    
-RUN cd /ws && git clone https://github.com/apache/incubator-mnemonic.git && \
+RUN touch /etc/profile.d/mvn.sh && chmod +x /etc/profile.d/mvn.sh && \
+    if [ "x" != "x${proxy_host}" ]; then echo export MAVEN_OPTS="\" -DproxySet=\\\"true\\\" -DproxyHost=${proxy_host} -DproxyPort=${proxy_port} \"" > /etc/profile.d/mvn.sh; fi
+
+RUN cat /etc/profile.d/mvn.sh > ~/.bash_profile
+RUN cat /etc/profile.d/mvn.sh > ~/.bashrc
+
+RUN . /etc/profile.d/mvn.sh && cd /ws && git clone https://github.com/apache/incubator-mnemonic.git && \
     cd incubator-mnemonic && mvn clean package install
 
 ENV MNEMONIC_HOME /ws/incubator-mnemonic