mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-24 07:53:19 +00:00
hedgedoc: move files to share/hedeodc in the package
This commit is contained in:
parent
26316368cb
commit
e91a7b7a4e
@ -236,9 +236,9 @@ in
|
||||
};
|
||||
|
||||
services.hedgedoc.settings = {
|
||||
defaultNotePath = lib.mkDefault "${cfg.package}/public/default.md";
|
||||
docsPath = lib.mkDefault "${cfg.package}/public/docs";
|
||||
viewPath = lib.mkDefault "${cfg.package}/public/views";
|
||||
defaultNotePath = lib.mkDefault "${cfg.package}/share/hedgedoc/public/default.md";
|
||||
docsPath = lib.mkDefault "${cfg.package}/share/hedgedoc/public/docs";
|
||||
viewPath = lib.mkDefault "${cfg.package}/share/hedgedoc/public/views";
|
||||
};
|
||||
|
||||
systemd.services.hedgedoc = {
|
||||
|
@ -84,18 +84,19 @@ in stdenv.mkDerivation {
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p $out
|
||||
cp -R {app.js,bin,lib,locales,node_modules,package.json,public} $out
|
||||
mkdir -p $out/share/hedgedoc
|
||||
cp -r bin $out
|
||||
cp -r {app.js,lib,locales,node_modules,package.json,public} $out/share/hedgedoc
|
||||
|
||||
for bin in $out/bin/*; do
|
||||
wrapProgram $bin \
|
||||
--set NODE_ENV production \
|
||||
--set NODE_PATH "$out/lib/node_modules"
|
||||
--set NODE_PATH "$out/share/hedgedoc/lib/node_modules"
|
||||
done
|
||||
makeWrapper ${nodejs}/bin/node $out/bin/hedgedoc \
|
||||
--add-flags $out/app.js \
|
||||
--add-flags $out/share/hedgedoc/app.js \
|
||||
--set NODE_ENV production \
|
||||
--set NODE_PATH "$out/lib/node_modules"
|
||||
--set NODE_PATH "$out/share/hedgedoc/lib/node_modules"
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
Loading…
Reference in New Issue
Block a user