nixpkgs/pkgs/applications/networking/cluster/talosctl/default.nix
zowoq 990bd301c1 talosctl: 1.0.6 -> 1.1.0
https://github.com/siderolabs/talos/releases/tag/v1.1.0

> b315ed9532
> Generate separate file for each variable and assign them during go build using go:embed instead of using ldflags -X.
2022-06-22 21:55:25 +10:00

43 lines
1.2 KiB
Nix

{ lib, stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
buildGoModule rec {
pname = "talosctl";
version = "1.1.0";
src = fetchFromGitHub {
owner = "siderolabs";
repo = "talos";
rev = "v${version}";
sha256 = "sha256-52WzQ5LWgIX/XBJPNvWV0tAPnw1AiINDL/7D3UYvvn4=";
};
vendorSha256 = "sha256-iluI4UGw5cZ70wmC9jDiGttvxZ7xFyqcL9IZX4ubJqs=";
ldflags = [ "-s" "-w" ];
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;
meta = with lib; {
description = "A CLI for out-of-band management of Kubernetes nodes created by Talos";
homepage = "https://www.talos.dev/";
license = licenses.mpl20;
maintainers = with maintainers; [ flokli ];
# requires >= 10.14 SDK https://github.com/NixOS/nixpkgs/issues/101229
# Undefined symbols for architecture x86_64: "_SecTrustEvaluateWithError"
broken = stdenv.isDarwin && stdenv.isx86_64;
};
}