File tree Expand file tree Collapse file tree 1 file changed +1
-4
lines changed
Expand file tree Collapse file tree 1 file changed +1
-4
lines changed Original file line number Diff line number Diff line change @@ -401,10 +401,8 @@ func newGHESHost(hostname string) (apiHost, error) {
401401}
402402
403403// checkSubdomainIsolation detects if GitHub Enterprise Server has subdomain isolation enabled
404- // by attempting to ping the raw._ping endpoint on the subdomain.
405- // Returns true if subdomain isolation is detected, false otherwise.
404+ // by attempting to ping the raw.<host>/_ping endpoint on the subdomain. The raw subdomain must always exist for subdomain isolation.
406405func checkSubdomainIsolation (scheme , hostname string ) bool {
407- // Try the subdomain isolation URL first: https://raw.hostname/_ping
408406 subdomainURL := fmt .Sprintf ("%s://raw.%s/_ping" , scheme , hostname )
409407
410408 client := & http.Client {
@@ -417,7 +415,6 @@ func checkSubdomainIsolation(scheme, hostname string) bool {
417415
418416 resp , err := client .Get (subdomainURL )
419417 if err != nil {
420- // If we can't reach the subdomain, assume no subdomain isolation
421418 return false
422419 }
423420 defer resp .Body .Close ()
You can’t perform that action at this time.
0 commit comments