Remove download redirects, use cdn.dl.k8s.io domain (#219)
dl.k8s.io redirects to cdn.dl.k8s.io which somehow results in constants download errors on a self-hosted runner in the UAE region. Other regions were not affected. Updating the domains fixed the issue
This commit is contained in:
+3
-3
@@ -14,14 +14,14 @@ export function getKubectlArch(): string {
|
||||
export function getkubectlDownloadURL(version: string, arch: string): string {
|
||||
switch (os.type()) {
|
||||
case 'Linux':
|
||||
return `https://dl.k8s.io/release/${version}/bin/linux/${arch}/kubectl`
|
||||
return `https://cdn.dl.k8s.io/release/${version}/bin/linux/${arch}/kubectl`
|
||||
|
||||
case 'Darwin':
|
||||
return `https://dl.k8s.io/release/${version}/bin/darwin/${arch}/kubectl`
|
||||
return `https://cdn.dl.k8s.io/release/${version}/bin/darwin/${arch}/kubectl`
|
||||
|
||||
case 'Windows_NT':
|
||||
default:
|
||||
return `https://dl.k8s.io/release/${version}/bin/windows/${arch}/kubectl.exe`
|
||||
return `https://cdn.dl.k8s.io/release/${version}/bin/windows/${arch}/kubectl.exe`
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user