diff --git a/nix/module.nix b/nix/module.nix index 970235e..da328bf 100644 --- a/nix/module.nix +++ b/nix/module.nix @@ -100,6 +100,7 @@ in User = cfg.user; Group = cfg.group; Restart = "always"; + WorkingDirectory = "${cfg.package}/web-app"; }; script = '' diff --git a/nix/package.nix b/nix/package.nix index c5b8354..871801e 100644 --- a/nix/package.nix +++ b/nix/package.nix @@ -32,12 +32,23 @@ let cp -r db/migrations/* $out/rest-api/db/migrations ''; }; + + templates = stdenv.mkDerivation { + inherit pname version; + name = "archtika-templates"; + src = ../templates; + installPhase = '' + mkdir -p $out/templates + cp -r * $out/templates + ''; + }; in symlinkJoin { name = pname; paths = [ web api + templates ]; meta = with lib; {