From d12a2a801b563459d91d557b7cb6eff5d8b1e8e9 Mon Sep 17 00:00:00 2001 From: Ubuntu Date: Mon, 28 Aug 2023 10:31:25 +0000 Subject: [PATCH] springapp --- dockerfile | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 dockerfile diff --git a/dockerfile b/dockerfile new file mode 100644 index 0000000..c9195c0 --- /dev/null +++ b/dockerfile @@ -0,0 +1,15 @@ +# Use an official OpenJDK runtime as the base image +FROM openjdk:11-jre-slim + +# Set the working directory within the container +WORKDIR /app + +# Copy the JAR file from your local build directory to the container +COPY target/spring-petclinic-3.1.0-SNAPSHOT.jar app.jar + +# Specify the command to run the application when the container starts +ENTRYPOINT ["java", "-jar", "app.jar"] + + + +