2024-10-17 21:42:16 -05:00
|
|
|
{ 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 ];
|
|
|
|
};
|
2024-10-11 12:12:09 -05:00
|
|
|
}
|