-
-
Notifications
You must be signed in to change notification settings - Fork 14.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
93 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12366,6 +12366,11 @@ | |
github = "krzaczek"; | ||
githubId = 5773701; | ||
}; | ||
kshlm = { | ||
name = "kshlm"; | ||
github = "kshlm"; | ||
githubId = 362086; | ||
}; | ||
KSJ2000 = { | ||
email = "[email protected]"; | ||
name = "KSJ2000"; | ||
|
@@ -21655,6 +21660,12 @@ | |
githubId = 203168; | ||
name = "Stefan Fehrenbach"; | ||
}; | ||
stefankeidel = { | ||
email = "[email protected]"; | ||
github = "stefankeidel"; | ||
githubId = 1188614; | ||
name = "Stefan Keidel"; | ||
}; | ||
stehessel = { | ||
email = "[email protected]"; | ||
github = "stehessel"; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
{ | ||
lib, | ||
buildGoModule, | ||
fetchFromGitHub, | ||
nodejs, | ||
nix-update-script, | ||
pnpm, | ||
stdenvNoCC, | ||
}: | ||
let | ||
pname = "cyphernetes"; | ||
version = "0.14.0"; | ||
src = fetchFromGitHub { | ||
owner = "AvitalTamir"; | ||
repo = "cyphernetes"; | ||
tag = "v${version}"; | ||
hash = "sha256-rxZWI+2eWMNTjphxS+lsxAoZUXD8wWF1pfe6hLBxtuM="; | ||
}; | ||
|
||
cyphernetes-web-ui = | ||
let | ||
pname = "cyphernetes-web-ui"; | ||
sourceRoot = "${src.name}/web"; | ||
in | ||
stdenvNoCC.mkDerivation { | ||
inherit | ||
pname | ||
version | ||
src | ||
sourceRoot | ||
; | ||
|
||
pnpmDeps = pnpm.fetchDeps { | ||
inherit | ||
pname | ||
version | ||
src | ||
sourceRoot | ||
; | ||
hash = "sha256-3uOBSVA4oyPDj9GLiBSPQonalaSYveJ4II01GTfaAUw="; | ||
}; | ||
nativeBuildInputs = [ | ||
nodejs | ||
pnpm.configHook | ||
]; | ||
buildPhase = '' | ||
runHook preBuild | ||
pnpm build | ||
runHook postBuild | ||
''; | ||
installPhase = '' | ||
runHook preInstall | ||
mkdir -p $out | ||
cp -R dist/* $out/ | ||
runHook postInstall | ||
''; | ||
}; | ||
in | ||
buildGoModule { | ||
inherit pname version src; | ||
vendorHash = "sha256-DRzYgpHShZn+17R1Jj/arwAP5lyTpWelmwloUxT3n5Y="; | ||
subPackages = [ "cmd/cyphernetes" ]; | ||
doCheck = false; # Tests need a kubeconfig with an active context configured | ||
preBuild = '' | ||
cp -r ${cyphernetes-web-ui} cmd/cyphernetes/web/ | ||
''; | ||
|
||
passthru.updateScript = nix-update-script { }; | ||
|
||
meta = { | ||
homepage = "https://cyphernet.es/"; | ||
changelog = "https://github.com/AvitalTamir/cyphernetes/releases/tag/v${version}"; | ||
description = "Kubernetes query language"; | ||
license = lib.licenses.asl20; | ||
maintainers = with lib.maintainers; [ | ||
kshlm | ||
stefankeidel | ||
]; | ||
mainProgram = "cyphernetes"; | ||
platforms = lib.platforms.linux ++ lib.platforms.darwin; | ||
}; | ||
} |