Don't try to login to ghcr.io with GHES tokens (#1291)

* Don't try GHXX tokens for ghcr.io login

* Explain hosted / onpremise in comment

* Nitfix variable name
This commit is contained in:
Ferenc Hammerl
2021-08-30 11:52:12 +02:00
committed by GitHub
parent 62d568674c
commit f61dcad5bb
2 changed files with 3 additions and 1 deletions

View File

@@ -117,6 +117,7 @@ namespace GitHub.Runner.Listener.Configuration
try
{
// Determine the service deployment type based on connection data. (Hosted/OnPremises)
// Hosted usually means github.com or localhost, while OnPremises means GHES or GHAE
runnerSettings.IsHostedServer = runnerSettings.GitHubUrl == null || UrlUtil.IsHostedServer(new UriBuilder(runnerSettings.GitHubUrl));
// Warn if the Actions server url and GHES server url has different Host