nixos/zfs: avoid script derivation for trim service
Since we only have a single pipe we can save the overhead of building a derivation when creating the zfs trim service file when building the system.
This commit is contained in:
parent
a412d90e10
commit
692656daf8
1 changed files with 1 additions and 3 deletions
|
@ -558,9 +558,7 @@ in
|
|||
after = [ "zfs-import.target" ];
|
||||
path = [ packages.zfsUser ];
|
||||
startAt = cfgTrim.interval;
|
||||
script = ''
|
||||
zpool list -H -o name | xargs --no-run-if-empty -n1 zpool trim
|
||||
'';
|
||||
serviceConfig.ExecStart = "${pkgs.runtimeShell} -c 'zpool list -H -o name | xargs --no-run-if-empty -n1 zpool trim'";
|
||||
};
|
||||
})
|
||||
];
|
||||
|
|
Loading…
Reference in a new issue