mirror of
https://github.com/gensokyo-zone/infrastructure.git
synced 2026-02-09 04:19:19 -08:00
feat(mediabox): mediatomb
This commit is contained in:
parent
2dfb1d9a4a
commit
59808530ec
3 changed files with 27 additions and 7 deletions
|
|
@ -48,7 +48,7 @@ in {
|
|||
config.systemd.services.mediatomb = mkIf cfg.enable {
|
||||
confinement.enable = mkIf cfg.confine (mkDefault true);
|
||||
bindsTo = map (dir: mkIf (dir.mountPoint != null)
|
||||
"${utils.escapeSystemdPath dir.mountPoint}"
|
||||
"${utils.escapeSystemdPath dir.mountPoint}.mount"
|
||||
) cfg.mediaDirectories;
|
||||
unitConfig.RequiresMountsFor = mkMerge (
|
||||
map (dir: dir.paths) cfg.mediaDirectories
|
||||
|
|
@ -56,7 +56,7 @@ in {
|
|||
serviceConfig = {
|
||||
RestartSec = mkDefault 15;
|
||||
StateDirectory = mkDefault cfg.package.pname;
|
||||
BindReadOnlyPaths = mkIf cfg.config (mkMerge (
|
||||
BindReadOnlyPaths = mkIf cfg.confine (mkMerge (
|
||||
map (dir: dir.paths) cfg.mediaDirectories
|
||||
));
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue