minecraft-helper/Dockerfile

21 lines
487 B
Docker
Raw Normal View History

2024-04-08 04:01:40 +00:00
FROM eclipse-temurin:17.0.10_7-jdk-focal
2024-04-08 04:03:41 +00:00
# Install maven
2024-04-08 04:01:40 +00:00
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y maven
2024-04-06 04:55:48 +00:00
2024-04-08 04:03:41 +00:00
# Set the working directory
WORKDIR /home/container
# Copy the current directory contents into the container at /home/container
2024-04-06 05:07:01 +00:00
COPY . .
2024-04-08 04:03:41 +00:00
# Build the jar
2024-04-08 03:59:51 +00:00
RUN mvn package -q
2024-04-06 04:55:48 +00:00
2024-04-08 04:03:41 +00:00
# Make port 80 available to the world outside this container
2024-04-06 05:21:30 +00:00
EXPOSE 80
ENV PORT=80
2024-04-06 05:06:19 +00:00
2024-04-08 04:03:41 +00:00
# Run the jar file
2024-04-06 04:55:48 +00:00
CMD ["java", "-jar", "target/Minecraft-Helper-1.0-SNAPSHOT.jar"]