maven不能下载jar包
详细问题:仓库配置正确,可通过网页访问到仓库的jar包,但是idea中项目中导入失败,报Could not transfer artifact xxx from/to xxx错误
解决方案:修改安全证书
-
在setting中maven里的importing和runner下的VM options,分别添加以下参数:
-Dmaven.wagon.http.ssl.insecure=true -Dmaven.wagon.http.ssl.allowall=true
-
还是报错,直接控制台运行以下命令
mvn clean install -Dmaven.test.skip=true -Dmaven.wagon.http.ssl.insecure=true -Dmaven.wagon.http.ssl.allowall=true