Skip to content

Commit

Permalink
Update Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
MClarkDev authored Aug 26, 2024
1 parent 15d729c commit 0114c73
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,19 +1,23 @@

# Build stage
# Build
FROM maven:3-openjdk-11-slim AS build
COPY src /home/app/src
COPY pom.xml /home/app
RUN mvn clean compile assembly:single -f /home/app/pom.xml

# Package stage
# Package
FROM openjdk:11-jre-slim
RUN apt update && apt install -y libfreetype-dev && rm -rf /var/lib/apt/lists/*
COPY --from=build /home/app/target/server.jar /usr/local/lib/server.jar
COPY config /config
COPY resources /resources

# Mounts
VOLUME /cache
VOLUME /config

# Ports
EXPOSE 8080
CMD ["java","-jar","/usr/local/lib/server.jar"]

# Command
CMD [ "java", "-jar", "/usr/local/lib/server.jar", "--language", "en_US", "--port", "8080" ]

0 comments on commit 0114c73

Please sign in to comment.