nixos/restic: use postStop for backupCleanupCommand
That way the `backupCleanupCommand` can also run when the backup service failed for some reason. Fixes: #182089. Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
This commit is contained in:
@@ -312,7 +312,7 @@ in
|
||||
''}
|
||||
'';
|
||||
} // optionalAttrs (backup.dynamicFilesFrom != null || backup.backupCleanupCommand != null) {
|
||||
postStart = ''
|
||||
postStop = ''
|
||||
${optionalString (backup.backupCleanupCommand != null) ''
|
||||
${pkgs.writeScript "backupCleanupCommand" backup.backupCleanupCommand}
|
||||
''}
|
||||
|
||||
Reference in New Issue
Block a user