nixos/frigate: don't clear model cache
Upstream stores the model cache in the config directory, which is unnecessarily messy. The cache directory is still the correct place for these, since they can be pruned and redownloaded, we just don't want it to happen on every restart. Fixes: #427714
This commit is contained in:
@@ -643,7 +643,8 @@ in
|
||||
serviceConfig = {
|
||||
ExecStartPre = [
|
||||
(pkgs.writeShellScript "frigate-clear-cache" ''
|
||||
rm --recursive --force /var/cache/frigate/*
|
||||
shopt -s extglob
|
||||
rm --recursive --force /var/cache/frigate/!(model_cache)
|
||||
'')
|
||||
(pkgs.writeShellScript "frigate-create-writable-config" ''
|
||||
cp --no-preserve=mode "${format.generate "frigate.yml" filteredConfig}" /run/frigate/frigate.yml
|
||||
|
||||
Reference in New Issue
Block a user