3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/networking/cluster/kubecfg/default.nix

34 lines
897 B
Nix
Raw Normal View History

{ lib, buildGoPackage, fetchFromGitHub, installShellFiles }:
2017-10-03 02:26:39 +01:00
buildGoPackage rec {
2019-08-13 22:52:01 +01:00
pname = "kubecfg";
2021-11-03 07:58:50 +00:00
version = "0.22.0";
2017-10-03 02:26:39 +01:00
src = fetchFromGitHub {
2019-06-26 19:57:37 +01:00
owner = "bitnami";
2017-10-03 02:26:39 +01:00
repo = "kubecfg";
rev = "v${version}";
2021-11-03 07:58:50 +00:00
sha256 = "sha256-8U/A4F4DboS46ftpuk5fQGT2Y0V+X0y0L3/o4x8qpnY=";
2017-10-03 02:26:39 +01:00
};
2019-06-26 19:57:37 +01:00
goPackagePath = "github.com/bitnami/kubecfg";
2017-10-03 02:26:39 +01:00
ldflags = [ "-s" "-w" "-X main.version=v${version}" ];
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
installShellCompletion --cmd kubecfg \
--bash <($out/bin/kubecfg completion --shell=bash) \
--zsh <($out/bin/kubecfg completion --shell=zsh)
'';
2017-10-03 02:26:39 +01:00
meta = {
description = "A tool for managing Kubernetes resources as code";
homepage = "https://github.com/bitnami/kubecfg";
2017-10-03 02:26:39 +01:00
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ benley ];
platforms = lib.platforms.unix;
};
}