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

Can't upload APK to Play on node behind proxy - Upload failed: Unknown error: java.net.SocketTimeoutException: connect timed out

XMLWordPrintable

      We use multiple nodes and master Jenkins all hosted on separate physical or VM servers.
      We upload APKs as part of stages that run on nodes.
      Upload to Google Play Console works fine on nodes that are not behind proxy but fails when node is behind the proxy (this node is CentOS VM and has already properly configured proxy environment variables independently from Jenkins: http_proxy, https_proxy, no_proxy).

      [2020-11-05T13:42:01.932Z] Authenticating to Google Play API...
      [2020-11-05T13:42:01.932Z] - Credential:    abc
      [2020-11-05T13:42:01.932Z] - Application ID: d.e.f
      [2020-11-05T13:42:01.933Z] 
      [2020-11-05T13:42:32.107Z] Upload failed: Unknown error: java.net.SocketTimeoutException: connect timed out
      [2020-11-05T13:42:32.107Z] No changes have been applied to the Google Play account
      

      Jenkins is already configured to use proxy as explained in plugin documentation and as suggested in JENKINS-31684 and JENKINS-64115 (Plugins->Advanced, passed at start via -Dhttp(s).proxyHost/Port... java options) .

      Also, I've tried withEnv as below (that works with simple sh steps fine) but the outcome in case of Android Publisher plugin is the same error:

                      stage('Upload') {
                          steps {
                              script {
                                  withEnv(['http_proxy=https://a.b.c.d:e', 'https_proxy=http://a.b.c.d:e']){
                                      androidApkUpload apkFilesPattern: 'some.apk', googleCredentialsId: 'some creds, trackName: 'internal'
                                  }
                              }
                          }
                      }
      

      orrc any suggestion if there's anything else that could be configured related to node behind proxy to enable the plugin functionality on it?

            orrc Christopher Orr
            marjanovic Dragan Marjanovic
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: