nixpkgs/pkgs/servers/pingvin-share/backend.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

51 lines
1.1 KiB
Nix
Raw Normal View History

2024-01-31 06:55:08 -05:00
{
lib,
buildNpmPackage,
vips,
pkg-config,
2024-08-27 14:14:29 -04:00
prisma,
2024-01-31 06:55:08 -05:00
src,
version,
2024-02-09 14:06:25 -05:00
nixosTests,
2024-01-31 06:55:08 -05:00
}:
buildNpmPackage {
pname = "pingvin-share-backend";
inherit version;
src = "${src}/backend";
npmInstallFlags = [ "--build-from-source" ];
installPhase = ''
cp -r . $out
ln -s $out/node_modules/.bin $out/bin
'';
preBuild = ''
prisma generate
'';
buildInputs = [ vips ];
nativeBuildInputs = [
pkg-config
2024-08-27 14:14:29 -04:00
prisma
2024-01-31 06:55:08 -05:00
];
2024-10-01 13:27:30 -04:00
npmDepsHash = "sha256-F+pYEsaU4Rsiq1z3rwGeKznZqpITF+AoFgswhTFeXf8=";
2024-01-31 06:55:08 -05:00
makeCacheWritable = true;
npmFlags = [ "--legacy-peer-deps" ];
2024-02-09 14:06:25 -05:00
passthru.tests = {
pingvin-share = nixosTests.pingvin-share;
};
2024-01-31 06:55:08 -05:00
meta = with lib; {
description = "Backend of pingvin-share, a self-hosted file sharing platform";
homepage = "https://github.com/stonith404/pingvin-share";
downloadPage = "https://github.com/stonith404/pingvin-share/releases";
changelog = "https://github.com/stonith404/pingvin-share/releases/tag/v${version}";
license = licenses.bsd2;
maintainers = with maintainers; [ ratcornu ];
};
}