mopidy: Add mopidy-scan service for scanning local media
This commit is contained in:
parent
05a3b156f0
commit
66858833e3
@ -92,6 +92,17 @@ in {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
systemd.services.mopidy-scan = {
|
||||||
|
description = "mopidy local files scanner";
|
||||||
|
preStart = "mkdir -p ${cfg.dataDir} && chown -R mopidy:mopidy ${cfg.dataDir}";
|
||||||
|
serviceConfig = {
|
||||||
|
ExecStart = "${mopidyLauncher}/bin/mopidy --config ${concatStringsSep ":" ([mopidyConf] ++ cfg.extraConfigFiles)} local scan";
|
||||||
|
User = "mopidy";
|
||||||
|
PermissionsStartOnly = true;
|
||||||
|
Type = "oneshot";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
users.extraUsers.mopidy = {
|
users.extraUsers.mopidy = {
|
||||||
inherit uid;
|
inherit uid;
|
||||||
group = "mopidy";
|
group = "mopidy";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user