Maven Failed to deploy artifacts: status: 405 PUT
问题现象
Failed to deploy artifacts: Could not transfer artifact http-sign-request-client:jar:1.0.0 from/to nexus-user (https:///repository/maven-public/): transfer failed for https:///repository/maven-public/c equest-client/1.0.0/http-sign-request-client-1.0.0.jar, status: 405 PUT
mvn deploy:deploy-file -DgroupId=xxx -DartifactId=http-sign-xxx-client -Dversion=1.0.0 -Dpacckaging=jar -Dfile=http-sign-request-xx-1.0.0.jar -DrepositoryId=nexus-user -Durl=https://xxx/repository/maven-public/
执行命令后报错
解决方法
修改命令如下
mvn deploy:deploy-file -DgroupId=x.xx-DartifactId=http-sign-request-xx-Dversion=1.0.0 -Dpacckaging=jar -Dfile=http-sign-request-xxx-1.0.0.jar -DrepositoryId=nexus-user -Durl=https://xxx/repository/maven-releases/
问题原因
deploy我们的jar包,应该使用hosted类型的nexus仓库。
文章来源: blog.csdn.net,作者:隔壁老瓦,版权归原作者所有,如需转载,请联系作者。
原文链接:blog.csdn.net/wxb880114/article/details/119108201
- 点赞
- 收藏
- 关注作者
评论(0)