dotfiles/modules/services/diskstation/default.nix

17 lines
433 B
Nix
Raw Normal View History

2021-09-14 23:01:04 +02:00
{ config, lib, pkgs, ... }:
{
2021-10-03 18:39:08 +02:00
fileSystems."/media/media" = {
device = "//192.168.0.2/media";
fsType = "cifs";
2021-11-29 11:56:35 +01:00
options = let
# this line prevents hanging on network split
automount_opts =
"x-systemd.automount,noauto,x-systemd.idle-timeout=60,x-systemd.device-timeout=5s,x-systemd.mount-timeout=5s";
2021-10-03 18:39:08 +02:00
2021-11-29 11:56:35 +01:00
in [
"${automount_opts},credentials=/run/agenix/smbMedia,uid=1000,gid=100"
];
2021-10-03 18:39:08 +02:00
};
2021-09-14 23:01:04 +02:00
}