From 0b360e932837087c70b869670abbb9eaaf0e3178 Mon Sep 17 00:00:00 2001 From: networkException Date: Mon, 2 Jun 2025 19:28:05 +0200 Subject: [PATCH] nixos/lasuite-docs: use systemd bind mount instead of stateful symlink for static directory --- nixos/modules/services/web-apps/lasuite-docs.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nixos/modules/services/web-apps/lasuite-docs.nix b/nixos/modules/services/web-apps/lasuite-docs.nix index eb1c44c2e87b..24a321aae825 100644 --- a/nixos/modules/services/web-apps/lasuite-docs.nix +++ b/nixos/modules/services/web-apps/lasuite-docs.nix @@ -264,7 +264,7 @@ in type = types.str; default = if cfg.enableNginx then "localhost,127.0.0.1,${cfg.domain}" else ""; defaultText = lib.literalExpression '' - if cfg.enableNginx then "localhost,127.0.0.1,$${cfg.domain}" else "" + if cfg.enableNginx then "localhost,127.0.0.1,''${cfg.domain}" else "" ''; description = "Comma-separated list of hosts that are able to connect to the server"; }; @@ -348,8 +348,6 @@ in wantedBy = [ "multi-user.target" ]; preStart = '' - ln -sfT ${cfg.backendPackage}/share/static /var/lib/lasuite-docs/static - if [ ! -f .version ]; then touch .version fi @@ -371,6 +369,8 @@ in environment = pythonEnvironment; serviceConfig = { + BindReadOnlyPaths = "${cfg.backendPackage}/share/static:/var/lib/lasuite-docs/static"; + ExecStart = utils.escapeSystemdExecArgs ( [ (lib.getExe' cfg.backendPackage "gunicorn")