mirror of
https://github.com/thiloho/archtika.git
synced 2025-11-22 10:51:36 +01:00
51 lines
1.0 KiB
Nix
51 lines
1.0 KiB
Nix
|
|
{
|
||
|
|
lib,
|
||
|
|
stdenv,
|
||
|
|
buildNpmPackage,
|
||
|
|
symlinkJoin,
|
||
|
|
}:
|
||
|
|
|
||
|
|
let
|
||
|
|
pname = "archtika";
|
||
|
|
version = "1.0.0";
|
||
|
|
|
||
|
|
web = buildNpmPackage {
|
||
|
|
inherit pname version;
|
||
|
|
name = "archtika-web-app";
|
||
|
|
src = ../web-app;
|
||
|
|
npmDepsHash = "sha256-DmIII/x5ANlEpKtnZC/JlbVAvhbgnSiNn8hkj+qVCZY=";
|
||
|
|
npmFlags = [ "--legacy-peer-deps" ];
|
||
|
|
installPhase = ''
|
||
|
|
mkdir -p $out/web-app
|
||
|
|
cp package.json $out/web-app
|
||
|
|
cp -r node_modules $out/web-app
|
||
|
|
cp -r build/* $out/web-app
|
||
|
|
'';
|
||
|
|
};
|
||
|
|
|
||
|
|
api = stdenv.mkDerivation {
|
||
|
|
inherit pname version;
|
||
|
|
name = "archtika-api";
|
||
|
|
src = ../rest-api;
|
||
|
|
installPhase = ''
|
||
|
|
mkdir -p $out/rest-api/db/migrations
|
||
|
|
cp -r db/migrations/* $out/rest-api/db/migrations
|
||
|
|
'';
|
||
|
|
};
|
||
|
|
in
|
||
|
|
symlinkJoin {
|
||
|
|
name = pname;
|
||
|
|
paths = [
|
||
|
|
web
|
||
|
|
api
|
||
|
|
];
|
||
|
|
|
||
|
|
meta = with lib; {
|
||
|
|
description = "A modern, performant and lightweight CMS";
|
||
|
|
homepage = "https://archtika.com";
|
||
|
|
license = licenses.mit;
|
||
|
|
maintainers = with maintainers; [ thiloho ];
|
||
|
|
platforms = platforms.unix;
|
||
|
|
};
|
||
|
|
}
|