当前位置 博文首页 > CHQIUU的专栏:Idea中发布JAR包到中央仓库报错问题处理 unable t

    CHQIUU的专栏:Idea中发布JAR包到中央仓库报错问题处理 unable t

    作者:[db:作者] 时间:2021-07-20 21:56

    报错信息如下:

    Failed to execute goal org.sonatype.plugins:nexus-staging-maven-plugin:1.6.8:deploy (injected-nexus-deploy) on project spring-redis-current-limit: Execution injected-nexus-deploy of goal org.sonatype.plugins:nexus-staging-maven-plugin:1.6.8:deploy failed: Nexus connection problem to URL [https://oss.sonatype.org/ ]: com.sun.jersey.api.client.ClientHandlerException: javax.net.ssl.SSLHandshakeException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

    image.png

    解决方法:

    增加配置参数,位置:File -> Settings -> Build, Execution, Deployment -> Build Tools -> Maven -> Runner,修改界面中VM Options参数为:

    -Dmaven.wagon.http.ssl.insecure=true -Dmaven.wagon.http.ssl.allowall=true
    

    ?image.png

    cs