From af6bd69db027c6632283d03947a1b3ac4eeac4d7 Mon Sep 17 00:00:00 2001 From: Sean McIlvenna Date: Fri, 14 Aug 2020 11:14:28 -0700 Subject: [PATCH] Combining base Dockerfile with main dockerfile so that there is a single image related to hapi-jpaserver-starter --- Dockerfile | 19 +++++++++++++++++-- Dockerfile.base | 13 ------------- 2 files changed, 17 insertions(+), 15 deletions(-) delete mode 100644 Dockerfile.base diff --git a/Dockerfile b/Dockerfile index e18d636..d0d2c40 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,10 +1,25 @@ -FROM hapiproject/hapi:base as build-hapi +FROM ubuntu as build-hapi + +ENV PATH="/tmp/apache-maven-3.6.0/bin:${PATH}" + +ENV TZ=Etc/UTC +RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone + +WORKDIR /tmp +RUN apt-get update && \ + apt-get install git -y && \ + apt-get install sed -y && \ + apt-get install wget -y && \ + apt-get install openjdk-11-jdk -y + +RUN wget https://downloads.apache.org/maven/maven-3/3.6.3/binaries/apache-maven-3.6.3-bin.tar.gz && tar xzf apache-maven-3.6.3-bin.tar.gz +RUN export PATH=/tmp/apache-maven-3.6.3/bin:${PATH} WORKDIR /tmp/hapi-fhir-jpaserver-starter COPY . . -RUN /tmp/apache-maven-3.6.2/bin/mvn clean install -DskipTests +RUN /tmp/apache-maven-3.6.3/bin/mvn clean install -DskipTests FROM tomcat:9-jre11 diff --git a/Dockerfile.base b/Dockerfile.base deleted file mode 100644 index d12c086..0000000 --- a/Dockerfile.base +++ /dev/null @@ -1,13 +0,0 @@ -FROM ubuntu - -ENV PATH="/tmp/apache-maven-3.6.0/bin:${PATH}" - -WORKDIR /tmp -RUN apt-get update && \ - apt-get install git -y && \ - apt-get install sed -y && \ - apt-get install wget -y && \ - apt-get install openjdk-11-jdk -y - -RUN wget https://www-us.apache.org/dist/maven/maven-3/3.6.2/binaries/apache-maven-3.6.2-bin.tar.gz && tar xzf apache-maven-3.6.2-bin.tar.gz -RUN export PATH=/tmp/apache-maven-3.6.2/bin:${PATH} \ No newline at end of file