diff options
author | Andy Mayer <am803u@att.com> | 2020-02-20 13:53:30 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2020-02-20 13:53:30 +0000 |
commit | 672a4638243434ac22408a7d352cf6ef3758879e (patch) | |
tree | e5f0515daaaa585cea263d036932d8e12237f774 | |
parent | 5ed2fc56576271bd09debf9016bf340cc99fe747 (diff) | |
parent | 1075a55b629873bc80449572ff0efa20bb61a914 (diff) |
Merge "updated Dockerfile"
-rw-r--r-- | Dockerfile | 18 |
1 files changed, 10 insertions, 8 deletions
@@ -16,12 +16,7 @@ FROM openjdk:11-jre-slim -ARG SERVER_PORT -ARG PKG_FILENAME=nbi-rest-services-5.0.1-SNAPSHOT.jar -ADD target/$PKG_FILENAME app.jar - -RUN addgroup appgroup && useradd -ms /bin/bash appuser && adduser appuser appgroup && mkdir temptoscafile && chown appuser:appgroup temptoscafile/ - +USER root COPY src/main/resources/certificate /certs ARG CERT_PASS=changeit RUN for cert in $(ls -d /certs/*); do \ @@ -34,7 +29,14 @@ RUN for cert in $(ls -d /certs/*); do \ --noprompt; \ done -USER appuser:appgroup +USER onap + +ARG SERVER_PORT +ARG PKG_FILENAME=nbi-rest-services-5.0.1-SNAPSHOT.jar +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} @@ -42,4 +44,4 @@ ENV JAVA_OPTS="-Dspring.profiles.active=ssl -Djava.security.egd=file:/dev/./uran EXPOSE $SERVER_PORT EXPOSE $HTTP_PORT -ENTRYPOINT java -XX:+UseContainerSupport $JAVA_OPTS -jar /app.jar +ENTRYPOINT java -XX:+UseContainerSupport $JAVA_OPTS -jar /opt/onap/app.jar |