Move the media share into options

This commit is contained in:
Andreas Zweili 2023-06-05 15:35:26 +02:00
parent 13f2f899c4
commit c1e453be1d
3 changed files with 18 additions and 6 deletions

View File

@ -27,6 +27,7 @@
./services/logs-share
./services/log-to-ram
./services/mariadb-for-containers
./media-share
./services/pipewire
./services/rclone-webdav
./services/rdp

View File

@ -1,8 +1,17 @@
{ ... }:
{ config, lib, ... }:
let
cfg = config.services.az-media-share;
in
{
fileSystems."/mnt/media" = {
device = "10.7.89.108:media";
fsType = "nfs";
options = [ "noatime" "hard" "nfsvers=4.0" ];
options = {
services.az-media-share.enable = lib.mkEnableOption "Mount the NFS share for with my media.";
};
config = lib.mkIf cfg.enable {
fileSystems."/mnt/media" = {
device = "10.7.89.108:media";
fsType = "nfs";
options = [ "noatime" "hard" "nfsvers=4.0" ];
};
};
}

View File

@ -10,7 +10,9 @@
tag = "plex";
time = "02:30";
})
"${inputs.self}/modules/media-share"
"${inputs.self}/modules/plex"
];
services = {
az-media-share.enable = true;
};
}