Skip to content

Commit

Permalink
Updated to reuse the executor.
Browse files Browse the repository at this point in the history
  • Loading branch information
nhkhai committed Apr 30, 2024
1 parent c8815a5 commit 40e3449
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
path: target/the-review-room-0.0.1-SNAPSHOT.jar

publish: # Also known as the build-and-push.
executor: docker/docker
executor: openjdk-with-postgres

steps:
- checkout
Expand Down
18 changes: 9 additions & 9 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,25 +9,25 @@ ENV PORT=9090
EXPOSE 9090

# The JAR file path.
# ARG JAR_FILE=*.jar
ARG JAR_FILE=*.jar
# ARG JAR_FILE=the-review-room-0.0.1-SNAPSHOT.jar

# Copy the JAR file from the build context into the Docker image.
# COPY target/${JAR_FILE} application.jar
COPY target/${JAR_FILE} application.jar

# Copy the source code into the Docker image.
COPY .mvn/ .mvn
COPY mvnw pom.xml ./
# COPY .mvn/ .mvn
# COPY mvnw pom.xml ./

COPY src ./src
# COPY src ./src

# Modify the permissions of the mvnw script.
RUN chmod +x ./mvnw
# RUN chmod +x ./mvnw

#CMD apt-get update -y

# Set the default command to run the Java application.
#ENTRYPOINT ["java", "-Xmx2048M", "-jar", "/application.jar"]
# ENTRYPOINT ["java","-jar","/application.jar"]
RUN ./mvnw install -DskipTests
CMD ["./mvnw", "spring-boot:run"]
ENTRYPOINT ["java","-jar","/application.jar"]
# RUN ./mvnw install -DskipTests
# CMD ["./mvnw", "spring-boot:run"]

0 comments on commit 40e3449

Please sign in to comment.