Failed to execute goal com.spotify:docker-maven-plugin:1.0.0:build (default-cli) on project boot-docker-demo: Exception caught: ADD failed: file not found in build context or...

❌ Docker构建镜像错误

Failed to execute goal com.spotify:docker-maven-plugin:1.0.0:build (default-cli) on project boot-docker-demo: 
Exception caught: ADD failed: file not found in build context or excluded by .dockerignore: stat spring-boot-docker-1.0.jar:
file does not exist -> [Help 1]

错误原因: pom.xml中jar文件配置出错没有添加后缀.jar

解决办法:

保证项目文件pom.xml中配置正确以及Dockerfile中文件名是可达的

posted @ 2021-03-29 16:52  Felix_Openmind  阅读(4833)  评论(0)    收藏  举报
*{cursor: url(https://files-cdn.cnblogs.com/files/morango/fish-cursor.ico),auto;}