mirror of
https://github.com/Azure/setup-kubectl.git
synced 2026-04-12 05:00:04 +00:00
Replace cdn.dl.k8s.io with dl.k8s.io (#227) (#228)
Some checks failed
Run prettify / Prettier Check (push) Has been cancelled
Run unit tests. / build (push) Has been cancelled
Integration test for setup-kubectl / Validate release and master branch (push) Has been cancelled
CodeQL Advanced / Analyze (javascript-typescript) (push) Has been cancelled
Some checks failed
Run prettify / Prettier Check (push) Has been cancelled
Run unit tests. / build (push) Has been cancelled
Integration test for setup-kubectl / Validate release and master branch (push) Has been cancelled
CodeQL Advanced / Analyze (javascript-typescript) (push) Has been cancelled
The cdn.dl.k8s.io domain is no longer available. Switch all download URLs back to dl.k8s.io.
This commit is contained in:
parent
8fd7ec08ee
commit
ef7e8f900a
3 changed files with 10 additions and 10 deletions
|
|
@ -14,14 +14,14 @@ export function getKubectlArch(): string {
|
|||
export function getkubectlDownloadURL(version: string, arch: string): string {
|
||||
switch (os.type()) {
|
||||
case 'Linux':
|
||||
return `https://cdn.dl.k8s.io/release/${version}/bin/linux/${arch}/kubectl`
|
||||
return `https://dl.k8s.io/release/${version}/bin/linux/${arch}/kubectl`
|
||||
|
||||
case 'Darwin':
|
||||
return `https://cdn.dl.k8s.io/release/${version}/bin/darwin/${arch}/kubectl`
|
||||
return `https://dl.k8s.io/release/${version}/bin/darwin/${arch}/kubectl`
|
||||
|
||||
case 'Windows_NT':
|
||||
default:
|
||||
return `https://cdn.dl.k8s.io/release/${version}/bin/windows/${arch}/kubectl.exe`
|
||||
return `https://dl.k8s.io/release/${version}/bin/windows/${arch}/kubectl.exe`
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -30,7 +30,7 @@ export async function getLatestPatchVersion(
|
|||
minor: string
|
||||
): Promise<string> {
|
||||
const version = `${major}.${minor}`
|
||||
const sourceURL = `https://cdn.dl.k8s.io/release/stable-${version}.txt`
|
||||
const sourceURL = `https://dl.k8s.io/release/stable-${version}.txt`
|
||||
try {
|
||||
const downloadPath = await toolCache.downloadTool(sourceURL)
|
||||
const latestPatch = fs
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue