update talos to unstable branch for latest go to compile

This commit is contained in:
Joseph Hanson 2024-10-17 21:42:16 -05:00
parent d5d2a7c888
commit 02cba3f46e
Signed by: jahanson
SSH key fingerprint: SHA256:vy6dKBECV522aPAwklFM3ReKAVB086rT3oWwiuiFG7o
4 changed files with 40 additions and 99 deletions

View file

@ -25,7 +25,7 @@ in
config.allowUnfree = true; config.allowUnfree = true;
} // { } // {
# Add talosctl to the unstable set # Add talosctl to the unstable set
talosctl = final.unstable.callPackage ./talosctl/talosctl-full.nix { talosctl = final.unstable.callPackage ./talosctl {
inherit (final.unstable) lib buildGoModule fetchFromGitHub installShellFiles; inherit (final.unstable) lib buildGoModule fetchFromGitHub installShellFiles;
}; };
}; };

View file

@ -1,16 +1,40 @@
{ ... }: { lib, buildGoModule, fetchFromGitHub, installShellFiles }:
let
finalVersion = "1.8.1"; buildGoModule rec {
in pname = "talosctl";
final: prev: { version = "1.8.1";
talosctl = prev.talosctl.overrideAttrs (oldAttrs: {
version = finalVersion; src = fetchFromGitHub {
src = prev.fetchFromGitHub { owner = "siderolabs";
owner = "siderolabs"; repo = "talos";
repo = "talos"; rev = "v${version}";
rev = "v${finalVersion}"; hash = "sha256-6WHeiVH/vZHiM4bqq3T5lC0ARldJyZtIErPeDgrZgxc=";
hash = "sha256-6WHeiVH/vZHiM4bqq3T5lC0ARldJyZtIErPeDgrZgxc="; };
};
vendorHash = "sha256-aTtvVpL979BUvSBwBqRqCWSWIBBmmty9vBD97Q5P4+E="; vendorHash = "sha256-aTtvVpL979BUvSBwBqRqCWSWIBBmmty9vBD97Q5P4+E=";
});
ldflags = [ "-s" "-w" ];
env.GOWORK = "off";
subPackages = [ "cmd/talosctl" ];
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
installShellCompletion --cmd talosctl \
--bash <($out/bin/talosctl completion bash) \
--fish <($out/bin/talosctl completion fish) \
--zsh <($out/bin/talosctl completion zsh)
'';
doCheck = false; # no tests
meta = with lib; {
description = "CLI for out-of-band management of Kubernetes nodes created by Talos";
mainProgram = "talosctl";
homepage = "https://www.talos.dev/";
license = licenses.mpl20;
maintainers = with maintainers; [ flokli ];
};
} }

View file

@ -1,43 +0,0 @@
{ lib, buildGo122Module, fetchFromGitHub, installShellFiles }:
buildGo122Module rec {
pname = "talosctl";
version = "1.7.5";
src = fetchFromGitHub {
owner = "siderolabs";
repo = "talos";
rev = "v${version}";
hash = "sha256-lmDLlxiPyVhlSPplYkIaS5Uw19hir6XD8MAk8q+obhY=";
};
passthru = {
updateScript = ./update.sh;
};
vendorHash = "sha256-8UIey+r1tdVRN1RBK5xxcAzaHb0VFdgenUXSFgoWh1g=";
ldflags = [ "-s" "-w" ];
env.GOWORK = "off";
subPackages = [ "cmd/talosctl" ];
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
installShellCompletion --cmd talosctl \
--bash <($out/bin/talosctl completion bash) \
--fish <($out/bin/talosctl completion fish) \
--zsh <($out/bin/talosctl completion zsh)
'';
doCheck = false; # no tests
meta = with lib; {
description = "CLI for out-of-band management of Kubernetes nodes created by Talos";
mainProgram = "talosctl";
homepage = "https://www.talos.dev/";
license = licenses.mpl20;
maintainers = with maintainers; [ flokli ];
};
}

View file

@ -1,40 +0,0 @@
{ lib, buildGoModule, fetchFromGitHub, installShellFiles }:
buildGoModule rec {
pname = "talosctl";
version = "1.8.1";
src = fetchFromGitHub {
owner = "siderolabs";
repo = "talos";
rev = "v${version}";
hash = "sha256-6WHeiVH/vZHiM4bqq3T5lC0ARldJyZtIErPeDgrZgxc=";
};
vendorHash = "sha256-aTtvVpL979BUvSBwBqRqCWSWIBBmmty9vBD97Q5P4+E=";
ldflags = [ "-s" "-w" ];
env.GOWORK = "off";
subPackages = [ "cmd/talosctl" ];
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
installShellCompletion --cmd talosctl \
--bash <($out/bin/talosctl completion bash) \
--fish <($out/bin/talosctl completion fish) \
--zsh <($out/bin/talosctl completion zsh)
'';
doCheck = false; # no tests
meta = with lib; {
description = "CLI for out-of-band management of Kubernetes nodes created by Talos";
mainProgram = "talosctl";
homepage = "https://www.talos.dev/";
license = licenses.mpl20;
maintainers = with maintainers; [ flokli ];
};
}