nixos/hqplayerd: don't add config to restartTriggers when it doesn't exist
Previously when the use didn't set `hqplayer.config`, we would still attempt to reference the config file in the restartTriggers, causing an error.
This commit is contained in:
parent
196138ea6b
commit
c934bb6771
@ -110,7 +110,7 @@ in
|
||||
|
||||
unitConfig.ConditionPathExists = [ configDir stateDir ];
|
||||
|
||||
restartTriggers = [ config.environment.etc."hqplayer/hqplayerd.xml".source ];
|
||||
restartTriggers = optionals (cfg.config != null) [ config.environment.etc."hqplayer/hqplayerd.xml".source ];
|
||||
|
||||
preStart = ''
|
||||
cp -r "${pkg}/var/lib/hqplayer/web" "${stateDir}"
|
||||
|
Loading…
Reference in New Issue
Block a user