summaryrefslogtreecommitdiffstats
path: root/Dockerfile
diff options
context:
space:
mode:
authoraosull01 <adrian.osullivan@huawei.com>2020-03-25 12:16:57 +0000
committeraosull01 <adrian.osullivan@huawei.com>2020-03-25 12:16:57 +0000
commitefb32d082a5b8463377ba91752dc25280d4b1cd4 (patch)
tree86d23efb0d481218da478dbcd517bdd335d53e07 /Dockerfile
parentc4b865137354f422efb46f0f6efa846d1353239d (diff)
Add JAVA_OPTS, SERVER_PORT and NBI_URL environment variable
Issue-ID: EXTAPI-417 Signed-off-by: aosull01 <adrian.osullivan@huawei.com> Change-Id: Ie8e65f65ea1a23ca27f0965a59a523dda70a4476
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile21
1 files changed, 3 insertions, 18 deletions
diff --git a/Dockerfile b/Dockerfile
index 701827e..3a8cd0c 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -16,19 +16,6 @@
FROM registry.gitlab.com/onap-integration/docker/onap-java
-USER root
-COPY src/main/resources/certificate /certs
-ARG CERT_PASS=changeit
-RUN for cert in $(ls -d /certs/*); do \
- echo "adding $cert to java keystore..."; \
- keytool -import \
- -file "$cert" \
- -storepass "${CERT_PASS}" \
- -keystore $JAVA_HOME/lib/security/cacerts \
- -alias "$(basename $cert)" \
- --noprompt; \
- done
-
USER onap
ARG SERVER_PORT
@@ -38,10 +25,8 @@ ADD target/$PKG_FILENAME /opt/onap/app.jar
RUN mkdir temptoscafile && chown onap:onap temptoscafile/
-ENV SERVER_PORT=${SERVER_PORT:-8443}
-ENV HTTP_PORT=${HTTP_PORT:-8080}
-ENV JAVA_OPTS="-Dspring.profiles.active=ssl -Djava.security.egd=file:/dev/./urandom"
+ENV SERVER_PORT=${SERVER_PORT:-8080}
+ENV JAVA_OPTS=${JAVA_OPTS:--Djava.security.egd=file:/dev/./urandom}
EXPOSE $SERVER_PORT
-EXPOSE $HTTP_PORT
-ENTRYPOINT java -XX:+UseContainerSupport $JAVA_OPTS -jar /opt/onap/app.jar
+ENTRYPOINT exec java -XX:+UseContainerSupport $JAVA_OPTS -jar /opt/onap/app.jar