Skip to content

Commit

Permalink
chore: Update Kind to latest (#806)
Browse files Browse the repository at this point in the history
  • Loading branch information
IvanJosipovic authored Nov 13, 2024
1 parent c1606a4 commit 4b9e28b
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions tests/KubeUI.Tests/Kind.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,12 @@

namespace KubeUI.Core.Tests;

/// <summary>
/// Interface for KIND https://github.com/kubernetes-sigs/kind/releases
/// </summary>
public class Kind
{
public string Version = "0.25.0";
public string Version = "latest";

public string FileName { get; } = "kind" + (RuntimeInformation.IsOSPlatform(OSPlatform.Windows) ? ".exe" : "");

Expand All @@ -24,18 +27,18 @@ public async Task DownloadClient()
arch = "arm64";
}

var os = $"linux-{arch}";
var os = "linux";

if (RuntimeInformation.IsOSPlatform(OSPlatform.OSX))
{
os = $"darwin-{arch}";
os = "darwin";
}
else if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
{
os = $"windows-{arch}";
os = "windows";
}

var url = $"https://kind.sigs.k8s.io/dl/v{Version}/kind-{os}";
var url = $"https://kind.sigs.k8s.io/dl/{Version}/kind-{os}-{arch}";

var bytes = await client.GetByteArrayAsync(url);

Expand Down

0 comments on commit 4b9e28b

Please sign in to comment.