summaryrefslogtreecommitdiffstats
path: root/conductor/docker/Dockerfile
diff options
context:
space:
mode:
authorIkramullah, Ikram <ikram@research.att.com>2019-04-24 22:30:17 +0000
committerIkramullah, Ikram <ikram@research.att.com>2019-04-24 22:31:07 +0000
commit49c1587a0900eba172e14adc0c93bb73d0fac9f8 (patch)
tree6517df998a687bc61c44edd10b12d32682d4990b /conductor/docker/Dockerfile
parent078c2cd8b26e2b0da47e7fdc6da305011c3d0c3e (diff)
Changes related to running oof on TLS/HTTPS
Change-Id: Ie20e65a70262f7b42e0eb9a033768e429d85f7d6 Issue-ID: OPTFRA-461 Signed-off-by: Ikramullah, Ikram <ikram@research.att.com>
Diffstat (limited to 'conductor/docker/Dockerfile')
-rw-r--r--[-rwxr-xr-x]conductor/docker/Dockerfile68
1 files changed, 32 insertions, 36 deletions
diff --git a/conductor/docker/Dockerfile b/conductor/docker/Dockerfile
index b68ebaf..b7528d8 100755..100644
--- a/conductor/docker/Dockerfile
+++ b/conductor/docker/Dockerfile
@@ -15,42 +15,38 @@
#
# -------------------------------------------------------------------------
-FROM python:2.7-alpine
+FROM python:2.7.15-alpine
+ENV CON_PORT "8091"
-ARG MVN_ARTIFACT_VERSION
-ARG REPO
-ARG HTTP_PROXY=${HTTP_PROXY}
-ARG HTTPS_PROXY=${HTTPS_PROXY}
+EXPOSE 8091
-ENV http_proxy $HTTP_PROXY
-ENV https_proxy $HTTPS_PROXY
-ENV CON_ADDR "127.0.0.1"
-ENV CON_PORT "8091"
+RUN mkdir -p /etc/nginx/ssl && \
+mkdir -p /var/log/conductor && \
+mkdir -p /run/conductor && \
+mkdir -p /run/nginx
+
+RUN apk --update add py-setuptools && \
+apk add unzip && \
+apk add curl && \
+apk add wget && \
+apk add fcgiwrap && \
+apk add bash vim && \
+apk add nginx
+
+RUN apk add py2-pip libpq python-dev
+RUN pip install --upgrade pip
+RUN apk add --virtual build-dependencies build-base linux-headers pcre-dev libffi-dev libxslt-dev libressl-dev
+RUN pip install uwsgi
+
+#Please leave teh following commmented out line in for test on local clusters
+#RUN wget -O /tmp/has.zip "https://nexus.onap.org/service/local/repositories/autorelease-121393/content/org/onap/optf/has/optf-has-conductor/1.2.5/optf-has-conductor-1.2.5.zip" && \
+RUN wget -O /tmp/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 /tmp/has.zip -d /tmp/has && \
+ rm -f /tmp/has.zip
+
+#PKG-INFO file must also exists in the conductor folder (i.e. besides and inside the of_has.egg-info folder). The zip file for distro above is missing it
+RUN cp /tmp/has/conductor/of_has.egg-info/PKG-INFO /tmp/has/conductor
+RUN pip install -e /tmp/has/conductor
-EXPOSE ${CON_PORT}
-
-# Add required libraries
-RUN apk add --no-cache curl \
- gcc \
- libffi-dev \
- linux-headers \
- musl-dev \
- git \
- libxml2-dev \
- libxslt-dev \
- openssl-dev \
- py-setuptools \
- unzip \
- wget \
- xvfb
-
-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 cd /opt/has/conductor && \
- git init && \
- pip install -e .
-COPY api_paste.ini /usr/local/bin/api_paste.ini
+COPY app.wsgi /etc/nginx/conductor.wsgi
+COPY api_paste.ini /usr/local/etc/conductor/api_paste.ini