mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-25 16:45:48 +00:00
docker file change
This commit is contained in:
parent
c189548f6b
commit
85809d5e1e
1 changed files with 3 additions and 13 deletions
16
Dockerfile
16
Dockerfile
|
@ -1,18 +1,8 @@
|
||||||
FROM mcr.microsoft.com/java/maven:8-zulu-debian10
|
FROM openjdk:8
|
||||||
|
|
||||||
RUN sudo yum update -y
|
ADD target/spring-petclinic-2.4.2.jar docker-spring-petclinic-boot.jar
|
||||||
|
|
||||||
WORKDIR /opt
|
|
||||||
|
|
||||||
COPY **/*.jar /opt/apache-tomcat-9.0.35/webapps/host-manager/WEB-INF/lib
|
|
||||||
|
|
||||||
COPY org.springframework.samples/spring-petclinic/2.4.2/spring-petclinic-2.4.2.jar /opt/apache-tomcat-9.0.35/webapps/host-manager/WEB-INF/lib
|
|
||||||
|
|
||||||
RUN ./mvnw spring-boot:run
|
|
||||||
|
|
||||||
EXPOSE 8081
|
EXPOSE 8081
|
||||||
|
|
||||||
RUN ./mvnw package
|
ENTRYPOINT [ "java" , "-jar", "docker-spring-petclinic-boot.jar" ]
|
||||||
|
|
||||||
CMD [ 'java', '-jar target/*.jar' ]
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue