Configure Studio and/or Robot thru a corporate proxy

Hi all.

We have recently upgraded to Studio 2022.4.x from an early version and we’ve found some errors with Studio and the corporate proxy. We’ve been able to solve “some” issues but there is still something that does not work: Package Management.

First of all, Studio is installed in SERVICE mode.
So, according to this page, we set the “proxy.pac” proxy file properly in “UiPath.config”.
Later, we stablished the environment variable (“UIPATH_PROXY_USE_DEFAULT_CREDENTIALS”) and restarted the UiPath service.

Now Studio can access other services thru the proxy. Ok.

But, when accesing, within Studio, to “Package Management” → “All Packages”, we are receiving an error like this:

The source package "Orchestrator Host" has found the following error:
"Unable to load the service index for source [inner corporate URL/other system]"

I must remind we are working with a corporate proxy, with windows credentials, and that Studio “finally” is working (it took us some weeks to set it working), but it seems some NuGet configuration is missing in any configuration file.

Can someone help us with this issue, please?

Many thanks in advance.

hi @agarcia.martin,

This post might be helpful to you: Unable to load service index for Official package source - #2 by gustavo.cervelin

Hope this helps. Happy automation!

Kind regards,
Kenneth

1 Like

Hi, @kennbalobalo!

Thanks; we already know it’s a “network issue”. Concretely it’s related with the “proxy settings” configuration from our corporation.

As I posted before, we’ve been able to properly configure Studio to perform api calls thru the proxy server; but, now, it’s time to configure NuGet for Studio to properly manage dependencies. And we do not know which file to edit, and what to set in within it.

AFAIK, we have (Studio globally) configured a source host (named: “Orchestrator Host”) which points to a internal URL (an URL in other system inside our organization, just where UIiPath Orchestrator resides) that needs also proxy authentication, just like Studio. And I think it’s something related with NuGet.

For Studio to work properly, we had had to edit “uipath.config” file, and now it works; but, which file to edit (and what to set) to properly configure NuGet for UiPath to bypass proxy server requests?

Thanks!

1 Like

hi @agarcia.martin ,

have you tried editing/adding the <config> in between the <configuration> tags inside the NuGet.config file with:

<config>
  <add key="http_proxy" value="[PROXY_ADDRESS]:[PROXY_PORT]" />
</config>

as mentioned in this article: Proxy setting for package manager - #10 by Nicolai_Kruger

I hope this helps.

Kind regards,
Kenneth

Well… actually with 2022.4.x version, there are, at least, THREE NuGet config files:

  1. The Studio config file, located at: [C:\Program Files\UiPath\Studio\NuGet.config],
  2. The “User Settings” config file, located at: [%APPDATA%\NuGet\NuGet.Config], and
  3. (MayBe) C:\Windows\SysWOW64\config\systemprofile\AppData\Roaming\NuGet location; as per this post.

Also, we would use a proxy configuration from a “proxy.pac” script file, not a static Proxy URL, and with windows credentials. This means we can NOT use: " http_proxy.user" or similar.

We’ll try, thanks!

1 Like

Final update.

For UiPath Studio to work properly with NuGet, this is the configuration I’ve found to make it work.

<?xml version="1.0" encoding="utf-8"?>
<!-- File: [%APPDATA%\NuGet\NuGet.Config] -->
<configuration>
	<packageSources>
		<add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3"/>
	</packageSources>
	<!-- more settings... -->
	<config>
		<!-- Proxy URL, NOT Proxy PAC Script URL!!! -->
		<add key="http_proxy" value="http://[hostname]:[port]"/>
	</config>
	<system.net>
		<defaultProxy useDefaultCredentials="true">
			<proxy autoDetect="True" usesystemdefault="True"/>
		</defaultProxy>
		<settings>
			<ipv6 enabled="true"/>
		</settings>
	</system.net>
</configuration>

Hope this serves. :wink:

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.