commit 07bc267665446f6a35c6f0b2a1d075a0ede14410
parent 5b87f50daf73c5cad72c3e181b9334c205163b78
Author: Francesco Saccone <francesco@francescosaccone.com>
Date: Wed, 16 Apr 2025 18:17:23 +0200
feat: remove unused 'symlinks' option and its implementation
Signed-off-by: Francesco Saccone <francesco@francescosaccone.com>
Diffstat:
1 file changed, 1 insertion(+), 33 deletions(-)
diff --git a/modules/nixos/quark/default.nix b/modules/nixos/quark/default.nix
@@ -23,14 +23,6 @@
readOnly = true;
type = lib.types.uniq lib.types.path;
};
- symlinks = lib.mkOption {
- description = ''
- For each symlink name, which will be created in the root directory, its
- target.
- '';
- default = { };
- type = lib.types.attrsOf lib.types.path;
- };
preStart = {
scripts = lib.mkOption {
description = ''
@@ -78,27 +70,6 @@
${pkgs.sbase}/bin/rm -rf \
${config.modules.quark.directory}/*
'';
- symlinks =
- config.modules.quark.symlinks
- |> builtins.mapAttrs (
- name: target:
- let
- inherit (config.modules.quark) directory;
- in
- ''
- ${pkgs.sbase}/bin/mkdir -p \
- ${directory}/${builtins.dirOf name}
-
- ${pkgs.sbase}/bin/ln -sf ${target} \
- ${directory}/${name}
-
- ${pkgs.sbase}/bin/chown -Rh darkhttpd:darkhttpd \
- ${directory}/${name}
- ''
- )
- |> builtins.attrValues
- |> builtins.concatStringsSep "\n"
- |> pkgs.writeShellScriptBin "symlinks";
in
{
User = "root";
@@ -107,7 +78,6 @@
ExecStart = [
"${permissions}/bin/permissions"
"${clean}/bin/clean"
- "${symlinks}/bin/symlinks"
];
};
};
@@ -149,9 +119,7 @@
enable = true;
wantedBy = [ "multi-user.target" ];
pathConfig = {
- PathModified = [
- config.modules.quark.directory
- ] ++ builtins.attrValues config.modules.quark.symlinks;
+ PathModified = [ config.modules.quark.directory ];
};
};
};