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

Does Jenkins supports Proxy server for PowerShell plugin

XMLWordPrintable

      Does Jenkins supports proxy server for PowerShell plugin.
      I am using proxy server to connect internet and executed below command in Jenkins job

      $Client = New-Object -TypeName System.Net.WebClient
      $Client.Proxy.Credentials = [System.Net.CredentialCache]::DefaultNetworkCredentials
      $Client.DownloadString('https://login.windows.net')

      Not able to connect throws exception as below

      Exception calling "DownloadString" with "1" argument(s): "Unable to connect to
      the remote server"
      At C:\AzureStackMigration\psauth.ps1:451 char:1
      + $Client.DownloadString('https://login.windows.net') > C:\AzureStackMi ...
      + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      + CategoryInfo : NotSpecified: ( [], MethodInvocationException
      + FullyQualifiedErrorId : WebException

      Can you let me know how to resolve this issue.

            Unassigned Unassigned
            kameshpudi Kamesh Pudi
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: