Skip to content

Commit

Permalink
cyphernetes: init at v0.15.3
Browse files Browse the repository at this point in the history
  • Loading branch information
kshlm committed Jan 28, 2025
1 parent 87b4b84 commit b8dc76a
Show file tree
Hide file tree
Showing 2 changed files with 93 additions and 0 deletions.
11 changes: 11 additions & 0 deletions maintainers/maintainer-list.nix
Original file line number Diff line number Diff line change
Expand Up @@ -12527,6 +12527,11 @@
github = "krzaczek";
githubId = 5773701;
};
kshlm = {
name = "kshlm";
github = "kshlm";
githubId = 362086;
};
KSJ2000 = {
email = "[email protected]";
name = "KSJ2000";
Expand Down Expand Up @@ -21970,6 +21975,12 @@
githubId = 203168;
name = "Stefan Fehrenbach";
};
stefankeidel = {
email = "[email protected]";
github = "stefankeidel";
githubId = 1188614;
name = "Stefan Keidel";
};
stehessel = {
email = "[email protected]";
github = "stehessel";
Expand Down
82 changes: 82 additions & 0 deletions pkgs/by-name/cy/cyphernetes/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
{
lib,
buildGoModule,
fetchFromGitHub,
nodejs,
nix-update-script,
pnpm_9,
stdenvNoCC,
}:
let
pname = "cyphernetes";
version = "0.15.3";
src = fetchFromGitHub {
owner = "AvitalTamir";
repo = "cyphernetes";
tag = "v${version}";
hash = "sha256-dNJo+6yXFwHU3k1CjloHWkUotsRYW3eJhkYeMmpvXYE=";
};

cyphernetes-web-ui =
let
pname = "cyphernetes-web-ui";
sourceRoot = "${src.name}/web";
in
stdenvNoCC.mkDerivation {
inherit
pname
version
src
sourceRoot
;

pnpmDeps = pnpm_9.fetchDeps {
inherit
pname
version
src
sourceRoot
;
hash = "sha256-3uOBSVA4oyPDj9GLiBSPQonalaSYveJ4II01GTfaAUw=";
};
nativeBuildInputs = [
nodejs
pnpm_9.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-QthLrLhi+hWngtc11nyFPU63exHZ0mh3IWWa8YHXFPA=";
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;
};
}

0 comments on commit b8dc76a

Please sign in to comment.