Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-58950

When trying to deploy with v2.0.0 of this plugin got error unable to find valid certification path to requested target.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • core

      When i updated plugin to v2, i always getting an error:

      ```
      {{ERROR: ERROR: java.lang.RuntimeException: io.kubernetes.client.ApiException: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
      hudson.remoting.ProxyException: java.lang.RuntimeException: io.kubernetes.client.ApiException: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
      at com.microsoft.jenkins.kubernetes.wrapper.ResourceManager.handleApiExceptionExceptNotFound(ResourceManager.java:140)
      at com.microsoft.jenkins.kubernetes.wrapper.V1ResourceManager$DeploymentUpdater.getCurrentResource(V1ResourceManager.java:191)
      at com.microsoft.jenkins.kubernetes.wrapper.V1ResourceManager$DeploymentUpdater.getCurrentResource(V1ResourceManager.java:179)
      at com.microsoft.jenkins.kubernetes.wrapper.ResourceManager$ResourceUpdater.createOrApply(ResourceManager.java:87)
      at com.microsoft.jenkins.kubernetes.wrapper.KubernetesClientWrapper.handleResource(KubernetesClientWrapper.java:182)
      at com.microsoft.jenkins.kubernetes.wrapper.KubernetesClientWrapper.apply(KubernetesClientWrapper.java:149)
      at com.microsoft.jenkins.kubernetes.command.DeploymentCommand$DeploymentTask.doCall(DeploymentCommand.java:265)
      at com.microsoft.jenkins.kubernetes.command.DeploymentCommand$DeploymentTask.call(DeploymentCommand.java:219)
      at com.microsoft.jenkins.kubernetes.command.DeploymentCommand$DeploymentTask.call(DeploymentCommand.java:202)
      at hudson.FilePath.act(FilePath.java:1163)
      at com.microsoft.jenkins.kubernetes.command.DeploymentCommand.execute(DeploymentCommand.java:164)
      at com.microsoft.jenkins.kubernetes.command.DeploymentCommand.execute(DeploymentCommand.java:52)
      at com.microsoft.jenkins.azurecommons.command.CommandService.runCommand(CommandService.java:88)
      at com.microsoft.jenkins.azurecommons.command.CommandService.execute(CommandService.java:96)
      at com.microsoft.jenkins.azurecommons.command.CommandService.executeCommands(CommandService.java:75)
      at com.microsoft.jenkins.azurecommons.command.BaseCommandContext.executeCommands(BaseCommandContext.java:77)
      at com.microsoft.jenkins.kubernetes.KubernetesDeploy.perform(KubernetesDeploy.java:42)
      at com.microsoft.jenkins.azurecommons.command.SimpleBuildStepExecution.run(SimpleBuildStepExecution.java:54)
      at com.microsoft.jenkins.azurecommons.command.SimpleBuildStepExecution.run(SimpleBuildStepExecution.java:35)
      at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      at java.lang.Thread.run(Thread.java:748)
      Caused by: hudson.remoting.ProxyException: io.kubernetes.client.ApiException: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
      at io.kubernetes.client.ApiClient.execute(ApiClient.java:805)
      at io.kubernetes.client.apis.AppsV1Api.readNamespacedDeploymentWithHttpInfo(AppsV1Api.java:6940)
      at io.kubernetes.client.apis.AppsV1Api.readNamespacedDeployment(AppsV1Api.java:6922)
      at com.microsoft.jenkins.kubernetes.wrapper.V1ResourceManager$DeploymentUpdater.getCurrentResource(V1ResourceManager.java:188)
      ... 23 more
      Caused by: hudson.remoting.ProxyException: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
      at sun.security.ssl.Alerts.getSSLException(Alerts.java:192)
      at sun.security.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1946)
      at sun.security.ssl.Handshaker.fatalSE(Handshaker.java:316)
      at sun.security.ssl.Handshaker.fatalSE(Handshaker.java:310)
      at sun.security.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:1639)
      at sun.security.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:223)
      at sun.security.ssl.Handshaker.processLoop(Handshaker.java:1037)
      at sun.security.ssl.Handshaker.process_record(Handshaker.java:965)
      at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1064)
      at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1367)
      at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1395)
      at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1379)
      at com.squareup.okhttp.internal.io.RealConnection.connectTls(RealConnection.java:192)
      at com.squareup.okhttp.internal.io.RealConnection.connectSocket(RealConnection.java:149)
      at com.squareup.okhttp.internal.io.RealConnection.connect(RealConnection.java:112)
      at com.squareup.okhttp.internal.http.StreamAllocation.findConnection(StreamAllocation.java:184)
      at com.squareup.okhttp.internal.http.StreamAllocation.findHealthyConnection(StreamAllocation.java:126)
      at com.squareup.okhttp.internal.http.StreamAllocation.newStream(StreamAllocation.java:95)
      at com.squareup.okhttp.internal.http.HttpEngine.connect(HttpEngine.java:281)
      at com.squareup.okhttp.internal.http.HttpEngine.sendRequest(HttpEngine.java:224)
      at com.squareup.okhttp.Call.getResponse(Call.java:286)
      at com.squareup.okhttp.Call$ApplicationInterceptorChain.proceed(Call.java:243)
      at com.squareup.okhttp.Call.getResponseWithInterceptorChain(Call.java:205)
      at com.squareup.okhttp.Call.execute(Call.java:80)
      at io.kubernetes.client.ApiClient.execute(ApiClient.java:801)
      ... 26 more
      Caused by: hudson.remoting.ProxyException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
      at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:397)
      at sun.security.validator.PKIXValidator.engineValidate(PKIXValidator.java:302)
      at sun.security.validator.Validator.validate(Validator.java:262)
      at sun.security.ssl.X509TrustManagerImpl.validate(X509TrustManagerImpl.java:324)
      at sun.security.ssl.X509TrustManagerImpl.checkTrusted(X509TrustManagerImpl.java:229)
      at sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:124)
      at sun.security.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:1621)
      ... 46 more
      Caused by: hudson.remoting.ProxyException: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
      at sun.security.provider.certpath.SunCertPathBuilder.build(SunCertPathBuilder.java:141)
      at sun.security.provider.certpath.SunCertPathBuilder.engineBuild(SunCertPathBuilder.java:126)
      at java.security.cert.CertPathBuilder.build(CertPathBuilder.java:280)
      at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:392)
      ... 52 more}}

      ```

      On v1.0.0 all is fine. I dont edit configs or something when switching versions.

            Unassigned Unassigned
            em1kky Mikhail K.
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: