You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@fineract.apache.org by aw...@apache.org on 2019/09/02 20:49:14 UTC

[fineract-cn-reporting] 01/01: Revert "FINCN-170 create multi-stage Docker build"

This is an automated email from the ASF dual-hosted git repository.

awasum pushed a commit to branch revert-10-multi-stage-docker-build
in repository https://gitbox.apache.org/repos/asf/fineract-cn-reporting.git

commit 7caec54a507e522016f5cfc5d66266382f5b14bc
Author: Awasum Yannick <ya...@gmail.com>
AuthorDate: Mon Sep 2 21:49:10 2019 +0100

    Revert "FINCN-170 create multi-stage Docker build"
---
 .dockerignore | 10 ++++++++++
 Dockerfile    | 13 +++----------
 2 files changed, 13 insertions(+), 10 deletions(-)

diff --git a/.dockerignore b/.dockerignore
index a3b6dc5..8d88495 100644
--- a/.dockerignore
+++ b/.dockerignore
@@ -1,7 +1,17 @@
+api/
+component-test/
+gradle/
+gradlew.bat
 LICENSE
 README.md
+settings.gradle
+build.gradle
 docs/
+gradlew
 HEADER
 NOTICE.txt
+service/
 .git/
+.gradle/
 .gitignore
+shared.gradle
\ No newline at end of file
diff --git a/Dockerfile b/Dockerfile
index 131a4ce..7079e8b 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -16,14 +16,7 @@
 # specific language governing permissions and limitations
 # under the License.
 #
-FROM openjdk:8-jdk-alpine AS builder
-RUN mkdir builddir
-COPY . builddir
-WORKDIR builddir
-RUN ./gradlew publishToMavenLocal
-
-
-FROM openjdk:8-jdk-alpine AS runner
+FROM openjdk:8-jdk-alpine
 
 ARG reporting_port=2029
 
@@ -32,7 +25,7 @@ ENV server.max-http-header-size=16384 \
     server.port=$reporting_port
 
 WORKDIR /tmp
-COPY --from=builder /builddir/service/build/libs/service-0.1.0-BUILD-SNAPSHOT-boot.jar ./reporting-service-boot.jar
+COPY reporting-service-boot-0.1.0-BUILD-SNAPSHOT.jar .
 ENV server.port=$reporting_port
 
-CMD ["java", "-jar", "reporting-service-boot.jar"]
+CMD ["java", "-jar", "reporting-service-boot-0.1.0-BUILD-SNAPSHOT.jar"]