From 2703d7ab7045089a381416d6e3b15df5f7e785ef Mon Sep 17 00:00:00 2001 From: Sebastien Premont-Tendland Date: Tue, 29 Oct 2019 17:32:54 -0400 Subject: [PATCH] Removed all http_proxy reference from build. http_proxy is an environment configuration and should not be defined in in the build script. If you need to use a proxy to build docker images then add it to the mvn command like this : -Ddocker.buildArg.http_proxy=$PROXY -Ddocker.buildArg.https_proxy=$PROXY Also adding http_proxy in the Dockerfile directly will add the environment variable in the POD statically using the proxy the was built with at runtime. If a proxy is needed at runtime then the environment variables should be injecting using helm charts and overrides. Issue-ID: CCSDK-1877 Signed-off-by: Sebastien Premont-Tendland Change-Id: I2b99b277b594408c974cf29a5804384293776a22 --- ms/blueprintsprocessor/application/pom.xml | 1 - ms/blueprintsprocessor/application/src/main/docker/Dockerfile | 5 +---- ms/command-executor/src/main/docker/Dockerfile | 5 +---- ms/py-executor/docker/Dockerfile | 5 +---- ms/sdclistener/distribution/src/main/docker/Dockerfile | 3 --- 5 files changed, 3 insertions(+), 16 deletions(-) diff --git a/ms/blueprintsprocessor/application/pom.xml b/ms/blueprintsprocessor/application/pom.xml index 3a95e8c84..0ee6ac339 100755 --- a/ms/blueprintsprocessor/application/pom.xml +++ b/ms/blueprintsprocessor/application/pom.xml @@ -38,7 +38,6 @@ org.onap.ccsdk.cds blueprintsprocessor onap/ccsdk-blueprintsprocessor - ${https_proxy} deploy true ${project.version} diff --git a/ms/blueprintsprocessor/application/src/main/docker/Dockerfile b/ms/blueprintsprocessor/application/src/main/docker/Dockerfile index dab0a4c01..207cec5cb 100755 --- a/ms/blueprintsprocessor/application/src/main/docker/Dockerfile +++ b/ms/blueprintsprocessor/application/src/main/docker/Dockerfile @@ -1,8 +1,5 @@ FROM omahoco1/alpine-java-python -ENV HTTP_PROXY ${HTTP_PROXY} -ENV HTTPS_PROXY ${HTTPS_PROXY} - # add entrypoint COPY run.source /etc/run.source COPY startService.sh /startService.sh @@ -15,4 +12,4 @@ RUN tar -xzf /source.tar.gz -C /tmp \ && rm -rf /source.tar.gz \ && rm -rf /tmp/@project.build.finalName@ -ENTRYPOINT /startService.sh \ No newline at end of file +ENTRYPOINT /startService.sh diff --git a/ms/command-executor/src/main/docker/Dockerfile b/ms/command-executor/src/main/docker/Dockerfile index c0458bdf6..b28e580fb 100644 --- a/ms/command-executor/src/main/docker/Dockerfile +++ b/ms/command-executor/src/main/docker/Dockerfile @@ -1,8 +1,5 @@ FROM python:3.6-slim -ENV HTTP_PROXY ${HTTP_PROXY} -ENV HTTPS_PROXY ${HTTPS_PROXY} - ENV GRPC_PYTHON_VERSION 1.20.0 RUN python -m pip install --upgrade pip RUN pip install grpcio==${GRPC_PYTHON_VERSION} grpcio-tools==${GRPC_PYTHON_VERSION} @@ -21,4 +18,4 @@ RUN tar -xzf /source.tar.gz -C /tmp \ VOLUME /opt/app/onap/blueprints/deploy/ -ENTRYPOINT /opt/app/onap/start.sh \ No newline at end of file +ENTRYPOINT /opt/app/onap/start.sh diff --git a/ms/py-executor/docker/Dockerfile b/ms/py-executor/docker/Dockerfile index b49daf68f..9e86cc87e 100644 --- a/ms/py-executor/docker/Dockerfile +++ b/ms/py-executor/docker/Dockerfile @@ -1,8 +1,5 @@ FROM python:3.7-slim -ENV HTTP_PROXY ${HTTP_PROXY} -ENV HTTPS_PROXY ${HTTPS_PROXY} - RUN mkdir -p /opt/app/onap/logs/ && touch /opt/app/onap/logs/application.log COPY @project.build.finalName@-@assembly.id@.tar.gz /source.tar.gz @@ -15,4 +12,4 @@ RUN pip install --no-cache-dir -r /opt/app/onap/python/requirements.txt VOLUME /opt/app/onap/blueprints/deploy/ -ENTRYPOINT /opt/app/onap/python/start.sh \ No newline at end of file +ENTRYPOINT /opt/app/onap/python/start.sh diff --git a/ms/sdclistener/distribution/src/main/docker/Dockerfile b/ms/sdclistener/distribution/src/main/docker/Dockerfile index e945188a8..34f6443bf 100755 --- a/ms/sdclistener/distribution/src/main/docker/Dockerfile +++ b/ms/sdclistener/distribution/src/main/docker/Dockerfile @@ -1,8 +1,5 @@ FROM openjdk:8-jdk-alpine -ENV HTTP_PROXY ${HTTP_PROXY} -ENV HTTPS_PROXY ${HTTPS_PROXY} - # add entrypoint COPY startService.sh /startService.sh RUN chmod 751 /startService.sh -- 2.16.6