post-alpha fixes for github.url github.api_url and github.graphql_url (#451)

This commit is contained in:
eric sciple
2020-04-24 13:38:59 -04:00
committed by GitHub
parent f798f5606b
commit 2fadf430e4
2 changed files with 4 additions and 3 deletions

View File

@@ -131,7 +131,7 @@ namespace GitHub.Runner.Worker
// Temporary hack for GHES alpha
var configurationStore = HostContext.GetService<IConfigurationStore>();
var runnerSettings = configurationStore.GetSettings();
if (!runnerSettings.IsHostedServer && !string.IsNullOrEmpty(runnerSettings.GitHubUrl))
if (string.IsNullOrEmpty(context.GetGitHubContext("url")) && !runnerSettings.IsHostedServer && !string.IsNullOrEmpty(runnerSettings.GitHubUrl))
{
var url = new Uri(runnerSettings.GitHubUrl);
var portInfo = url.IsDefaultPort ? string.Empty : $":{url.Port.ToString(CultureInfo.InvariantCulture)}";