diff options
| author | Fuwn <[email protected]> | 2024-11-01 23:34:05 -0700 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2024-11-01 23:34:05 -0700 |
| commit | d0ed99c3bb411c7c6ef274f2d4822e5800cf3d6e (patch) | |
| tree | 95e45c0edfb26935aa9a1a475c25e6f0557f2d89 /hosts/shared/hardware-configuration.nix | |
| parent | lock: all but hyprwm (diff) | |
| download | nixos-config-d0ed99c3bb411c7c6ef274f2d4822e5800cf3d6e.tar.xz nixos-config-d0ed99c3bb411c7c6ef274f2d4822e5800cf3d6e.zip | |
hosts: kioku mount options
Diffstat (limited to 'hosts/shared/hardware-configuration.nix')
| -rw-r--r-- | hosts/shared/hardware-configuration.nix | 46 |
1 files changed, 29 insertions, 17 deletions
diff --git a/hosts/shared/hardware-configuration.nix b/hosts/shared/hardware-configuration.nix index aea9310..eed2ce3 100644 --- a/hosts/shared/hardware-configuration.nix +++ b/hosts/shared/hardware-configuration.nix @@ -1,21 +1,33 @@ { config, ... }: { - fileSystems."/mnt/kioku" = { - device = "//kioku/usb"; - fsType = "cifs"; + fileSystems."/mnt/kioku" = + let + sharedOptions = [ + "x-systemd.automount" + "noauto" + "x-systemd.idle-timeout=60" + "x-systemd.device-timeout=5s" + "x-systemd.mount-timeout=5s" + "rw" + "nofail" + "noatime" + "uid=1000" + "gid=1000" + ]; + in + if config.modules.mounts.kioku.withSamba then + { + device = "//kioku/usb"; + fsType = "cifs"; - options = [ - "x-systemd.automount" - "noauto" - "x-systemd.idle-timeout=60" - "x-systemd.device-timeout=5s" - "x-systemd.mount-timeout=5s" - "rw" - "nofail" - "noatime" - "credentials=${config.sops.secrets.samba_secrets.path}" - "uid=1000" - "gid=1000" - ]; - }; + options = [ + "credentials=${config.sops.secrets.samba_secrets.path}" + ] ++ sharedOptions; + } + else + { + device = "/dev/disk/by-uuid/67BF-FE53"; + fsType = "exfat"; + options = sharedOptions; + }; } |