diff options
author | OTABI Tomoya <tomoya.otabi@gmail.com> | 2023-08-23 15:41:28 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-23 15:41:28 +0900 |
commit | babf87cb69af17ef7b86fd4fe5f352fd8516d611 (patch) | |
tree | 4748724e21a1e3cc28d21c4dac9588f6ee6272a1 /pkgs/applications | |
parent | 96577a3736c70839e712214e7cb138b0cbb45626 (diff) | |
parent | 23434b89f9022fe909dc777e60b8573c215458b7 (diff) |
Merge pull request #249810 from mmlb/feat/add-kns
kns: init at unstable-2023-04-25
Diffstat (limited to 'pkgs/applications')
-rw-r--r-- | pkgs/applications/networking/cluster/kns/default.nix | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/pkgs/applications/networking/cluster/kns/default.nix b/pkgs/applications/networking/cluster/kns/default.nix new file mode 100644 index 0000000000000..522209d591836 --- /dev/null +++ b/pkgs/applications/networking/cluster/kns/default.nix @@ -0,0 +1,38 @@ +{ stdenvNoCC +, lib +, fetchFromGitHub +, fzf +, kubectl +}: +stdenvNoCC.mkDerivation { + pname = "kns"; + version = "unstable-2023-04-25"; + + src = fetchFromGitHub { + owner = "blendle"; + repo = "kns"; + rev = "86502949c31432bd95895cfb26d1c5893c533d5c"; + hash = "sha256-8AR/fEKPAfiKCZrp/AyJo3Ic8dH7SfncYZSdQA2GywQ="; + }; + + strictDeps = true; + + buildInputs = [ fzf kubectl ]; + + installPhase = '' + runHook preInstall + + substituteInPlace bin/kns bin/ktx --replace fzf ${fzf}/bin/fzf --replace kubectl ${kubectl}/bin/kubectl + install -D -m755 -t $out/bin bin/kns bin/ktx + + runHook postInstall + ''; + + meta = with lib; { + description = "Kubernetes namespace switcher"; + homepage = "https://github.com/blendle/kns"; + license = licenses.isc; + maintainers = with maintainers; [ mmlb ]; + platforms = platforms.linux; + }; +} |