GitHub Sync With Proxy

Product: PowerShell Universal
Version: 3.3.5

I tried using the out-of-the-box git sync with the proxy environment variable set but quickly realized that wasn’t going to work. I then installed the git CLI, configured it, and got it authenticated with GitHub using the gh auth login command.

However, when I try to make changes to the git settings in the UI they don’t stick, and the sync still fails. I thought this might be because I have my git settings set in appsettings.json. So, I removed those settings. When I do that and restart the services, I get stuck on this screen.

image

How do I set the option to use the external git client in appsettings.json? Should I do something else?

Error From Log

2022-09-27 14:29:25.710 -04:00 [ERR] Failed to sync: failed to send request: A connection with the server could not be established
at LibGit2Sharp.Core.Ensure.HandleError(Int32 result) in //LibGit2Sharp/Core/Ensure.cs:line 154
at LibGit2Sharp.Core.Ensure.ZeroResult(Int32 result) in /
/LibGit2Sharp/Core/Ensure.cs:line 172
at LibGit2Sharp.Core.Proxy.git_remote_fetch(RemoteHandle remote, IEnumerable1 refSpecs, GitFetchOptions fetchOptions, String logMessage) in /_/LibGit2Sharp/Core/Proxy.cs:line 2289 at LibGit2Sharp.Commands.Fetch(Repository repository, String remote, IEnumerable1 refspecs, FetchOptions options, String logMessage) in //LibGit2Sharp/Commands/Fetch.cs:line 80
at LibGit2Sharp.Commands.Pull(Repository repository, Signature merger, PullOptions options) in /
/LibGit2Sharp/Commands/Pull.cs:line 37
at UniversalAutomation.Git.GitService.Pull() in C:\actions-runner_work\universal\universal\src\Universal.Server\Services\GitService.cs:line 354
at UniversalAutomation.GitSyncService.TrySync(GitStatus status, Boolean force, GitSettings settings) in C:\actions-runner_work\universal\universal\src\Universal.Server\Services\GitSyncService.cs:line 139
at UniversalAutomation.GitSyncService.Sync(Boolean force) in C:\actions-runner_work\universal\universal\src\Universal.Server\Services\GitSyncService.cs:line 84

In your appsettings.json, you can use the following to use the external git client:

"Data": {
   "ExternalGitClient" : true
}

I’ll make sure we get this into the docs. Based on your log, it’s not using the external git client.