diff options
author | Christopher Lott (cl778h) <clott@research.att.com> | 2017-08-23 18:27:19 -0400 |
---|---|---|
committer | Christopher Lott (cl778h) <clott@research.att.com> | 2017-08-23 21:12:56 -0400 |
commit | 978dbcf0a196acbafad72fe1e2478ec0e384f02f (patch) | |
tree | 17e1ceaa4a12a599320cbb317947e990bf1a5383 /deliveries/Dockerfile.portalapps | |
parent | bc7350dce5b7b1dcd1c472a3922b42c4ea99809d (diff) |
Deliver centralized role management feature
Repair multiple defects also.
Revise deployment to use docker-compose.
Remove all zip archives.
Issue: PORTAL-21, PORTAL-25, PORTAL-28, PORTAL-52, PORTAL-69,
PORTAL-74, PORTAL-76, PORTAL-80, PORTAL-82
Change-Id: Ie72fec7d35ba78beb162bba6ed27b2caee340c61
Signed-off-by: Christopher Lott (cl778h) <clott@research.att.com>
Diffstat (limited to 'deliveries/Dockerfile.portalapps')
-rw-r--r-- | deliveries/Dockerfile.portalapps | 33 |
1 files changed, 23 insertions, 10 deletions
diff --git a/deliveries/Dockerfile.portalapps b/deliveries/Dockerfile.portalapps index 3e295e8f..c9fab4db 100644 --- a/deliveries/Dockerfile.portalapps +++ b/deliveries/Dockerfile.portalapps @@ -1,7 +1,10 @@ # Dockerfile for image with ONAP applications: # Portal app, Portal-SDK app, Portal-DBC app. -FROM openjdk:8-jdk +# Yields an image 823 MB +FROM frolvlad/alpine-oraclejdk8:slim +# Yields an image 1.4 GB +# FROM openjdk:8-jdk # Arguments are supplied by build.sh script # the defaults below only support testing @@ -12,21 +15,28 @@ ARG DBC_WAR=build/dmaap-bc-app-os.war ARG HTTP_PROXY ARG HTTPS_PROXY -# This is just a variable, never passed in -ARG TOMCATHOME=/opt/apache-tomcat-8.0.37 +# Just variables, never passed in +ARG TOMCAT=apache-tomcat-8.0.37 +ARG TOMCATTAR=${TOMCAT}.tar.gz +ARG TOMCATHOME=/opt/${TOMCAT} ENV http_proxy $HTTP_PROXY ENV https_proxy $HTTPS_PROXY RUN if [ ! -z ${HTTP_PROXY} ]; then echo "Acquire::http::proxy \"${HTTP_PROXY}\";" >> /etc/apt/apt.conf; fi && \ if [ ! -z ${HTTPS_PROXY} ]; then echo "Acquire::https::proxy \"${HTTPS_PROXY}\";" >> /etc/apt/apt.conf; fi -# Install Tomcat; curl is already part of this image +# Install the wait script +COPY wait-for.sh / + +# Install Tomcat. This image already has curl. WORKDIR /tmp -RUN curl -s -O https://archive.apache.org/dist/tomcat/tomcat-8/v8.0.37/bin/apache-tomcat-8.0.37.tar.gz -RUN tar -xzf apache-tomcat-8.0.37.tar.gz +RUN wget -q http://archive.apache.org/dist/tomcat/tomcat-8/v8.0.37/bin/apache-tomcat-8.0.37.tar.gz +RUN tar -xzf ${TOMCATTAR} +RUN rm ${TOMCATTAR} # Remove manager and sample apps -RUN rm -fr apache-tomcat-8.0.37/webapps/[a-z]* -RUN mv apache-tomcat-8.0.37 /opt +RUN rm -fr ${TOMCAT}/webapps/[a-z]* +RUN mkdir -p /opt +RUN mv ${TOMCAT} /opt WORKDIR ${TOMCATHOME}/webapps RUN mkdir ECOMPPORTAL && mkdir ECOMPSDKAPP && mkdir ECOMPDBCAPP @@ -46,9 +56,12 @@ RUN cd ECOMPDBCAPP && unzip -q *.war && rm *.war VOLUME ${TOMCATHOME}/logs +# Switch back to root +WORKDIR / + # Define commonly used ENV variables ENV PATH $PATH:$JAVA_HOME/bin:${TOMCATHOME}/bin -COPY configure-and-run.sh / +COPY start-apps-cmd.sh / # Define default command. -CMD ["/configure-and-run.sh"] +CMD /start-apps-cmd.sh |