uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
60
pkgs/applications/networking/cluster/talosctl/default.nix
Normal file
60
pkgs/applications/networking/cluster/talosctl/default.nix
Normal file
|
|
@ -0,0 +1,60 @@
|
|||
{ lib, buildGoModule, fetchFromGitHub, installShellFiles }:
|
||||
let
|
||||
# look for GO_LDFLAGS getting set in the Makefile
|
||||
version = "1.0.5";
|
||||
sha256 = "sha256-xgzIbhgV1AAUa0tooYtzUMqK4Co3PvWQ0YbZuf0JgFE=";
|
||||
vendorSha256 = "sha256-Gp30qCGV+EaJ1lvfleZHRWVL6rdSj0mvpumWsqr9IT0=";
|
||||
pkgsVersion = "v1.0.0-17-g7567bf4";
|
||||
extrasVersion = "v1.0.0-3-g6327c36";
|
||||
in
|
||||
buildGoModule rec {
|
||||
pname = "talosctl";
|
||||
inherit version vendorSha256;
|
||||
# nixpkgs-update: no auto update
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "siderolabs";
|
||||
repo = "talos";
|
||||
rev = "v${version}";
|
||||
inherit sha256;
|
||||
};
|
||||
|
||||
ldflags =
|
||||
let
|
||||
versionPkg = "github.com/talos-systems/talos/pkg/version"; # VERSION_PKG
|
||||
imagesPkgs = "github.com/talos-systems/talos/pkg/images"; # IMAGES_PKGS
|
||||
mgmtHelpersPkg = "github.com/talos-systems/talos/cmd/talosctl/pkg/mgmt/helpers"; #MGMT_HELPERS_PKG
|
||||
in
|
||||
[
|
||||
"-X ${versionPkg}.Name=Client"
|
||||
"-X ${versionPkg}.SHA=${src.rev}" # should be the hash, but as we build from tags, this needs to do
|
||||
"-X ${versionPkg}.Tag=${src.rev}"
|
||||
"-X ${versionPkg}.PkgsVersion=${pkgsVersion}" # PKGS
|
||||
"-X ${versionPkg}.ExtrasVersion=${extrasVersion}" # EXTRAS
|
||||
"-X ${imagesPkgs}.Username=siderolabs" # USERNAME
|
||||
"-X ${imagesPkgs}.Registry=ghcr.io" # REGISTRY
|
||||
"-X ${mgmtHelpersPkg}.ArtifactsPath=_out" # ARTIFACTS
|
||||
"-s"
|
||||
"-w"
|
||||
];
|
||||
|
||||
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 ];
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue