mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-01-21 17:31:34 +01:00
Rename dependentService to conflictingService
This commit is contained in:
parent
73e0441fd4
commit
bf87931934
7 changed files with 15 additions and 18 deletions
|
|
@ -40,15 +40,15 @@ in
|
|||
name = "restic-restore-${name}";
|
||||
text =
|
||||
let
|
||||
inherit (value) dependentService;
|
||||
hasDependentService = dependentService != null;
|
||||
inherit (value) conflictingService;
|
||||
hasconflictingService = conflictingService != null;
|
||||
in
|
||||
''
|
||||
${lib.optionalString hasDependentService "systemctl stop ${dependentService}"}
|
||||
${lib.optionalString hasconflictingService "systemctl stop ${conflictingService}"}
|
||||
${value.restoreCommand.preRestore}
|
||||
restic-${name} restore latest --target /
|
||||
${value.restoreCommand.postRestore}
|
||||
${lib.optionalString hasDependentService "systemctl start ${dependentService}"}
|
||||
${lib.optionalString hasconflictingService "systemctl start ${conflictingService}"}
|
||||
'';
|
||||
}
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue