From abeb634c05d63739e27d05534e5c03cefffd8504 Mon Sep 17 00:00:00 2001 From: Dileep Ranganathan Date: Mon, 23 Jul 2018 07:16:25 -0700 Subject: Fix Docker image to use the nexus artifacts Fixed Docker image to use the nexus artifacts instead of building from source. Added proxy support. Updated the Docker image version for Casablanca. Change-Id: I42de44b5c09992822696b1e12344ac6fde51373d Issue-ID: OPTFRA-301 Signed-off-by: Dileep Ranganathan --- conductor/docker/Dockerfile | 25 ++++++++++++++++++------- 1 file changed, 18 insertions(+), 7 deletions(-) (limited to 'conductor') diff --git a/conductor/docker/Dockerfile b/conductor/docker/Dockerfile index 693e458..0222c9f 100755 --- a/conductor/docker/Dockerfile +++ b/conductor/docker/Dockerfile @@ -16,17 +16,28 @@ # ------------------------------------------------------------------------- FROM python:2.7 + +ARG MVN_ARTIFACT_VERSION +ARG REPO +ARG HTTP_PROXY=${HTTP_PROXY} +ARG HTTPS_PROXY=${HTTPS_PROXY} + +ENV http_proxy $HTTP_PROXY +ENV https_proxy $HTTPS_PROXY ENV CON_ADDR "127.0.0.1" ENV CON_PORT "8091" -EXPOSE 8091 +EXPOSE ${CON_PORT} RUN apt-get update && apt-get --assume-yes install python-setuptools && \ -apt-get install -y unzip && \ -apt-get install -y curl && \ -apt-get install -y wget +apt-get install -y unzip curl wget git vim + +# HAS +WORKDIR /opt/has +RUN wget -O /opt/has.zip "https://nexus.onap.org/service/local/artifact/maven/redirect?r=${REPO}&g=org.onap.optf.has&a=optf-has-conductor&e=zip&v=${MVN_ARTIFACT_VERSION}" && \ + unzip -q -o -B /opt/has.zip -d /opt/has && \ + rm -f /opt/has.zip +RUN mkdir -p /var/log/onap/optf/has/ -RUN git clone https://gerrit.onap.org/r/optf/has \ - && git checkout beijing -RUN cd ./has/conductor/ && pip install -e . +RUN cd /opt/has/conductor/ && git init && pip install -e . COPY api_paste.ini /usr/local/bin/api_paste.ini -- cgit 1.2.3-korg