fix smb mount
This commit is contained in:
parent
01e9991f6e
commit
ecc84e35bd
@ -2,7 +2,11 @@
|
|||||||
with rec {
|
with rec {
|
||||||
inherit (config) device deviceSpecific secrets;
|
inherit (config) device deviceSpecific secrets;
|
||||||
};
|
};
|
||||||
with deviceSpecific; {
|
with deviceSpecific;
|
||||||
|
# let
|
||||||
|
# wgEnabled = config.secrets.wireguard.${config.device}.enable;
|
||||||
|
# in
|
||||||
|
{
|
||||||
fileSystems = {
|
fileSystems = {
|
||||||
"/shared/nixos" = lib.mkIf isVM {
|
"/shared/nixos" = lib.mkIf isVM {
|
||||||
fsType = "vboxsf";
|
fsType = "vboxsf";
|
||||||
@ -23,7 +27,6 @@ with deviceSpecific; {
|
|||||||
fsType = "ntfs";
|
fsType = "ntfs";
|
||||||
device = "/dev/disk/by-partuuid/944f923d-cf08-4752-bf3f-8aa8e0190260";
|
device = "/dev/disk/by-partuuid/944f923d-cf08-4752-bf3f-8aa8e0190260";
|
||||||
options = [
|
options = [
|
||||||
# "ro"
|
|
||||||
# "noatime"
|
# "noatime"
|
||||||
"nofail"
|
"nofail"
|
||||||
"uid=${toString config.users.users.alukard.uid}"
|
"uid=${toString config.users.users.alukard.uid}"
|
||||||
@ -34,20 +37,26 @@ with deviceSpecific; {
|
|||||||
fsType = "cifs";
|
fsType = "cifs";
|
||||||
device = "//192.168.0.100/data";
|
device = "//192.168.0.100/data";
|
||||||
options = [
|
options = [
|
||||||
# "ro"
|
|
||||||
"user=${secrets.linux-samba.user}"
|
"user=${secrets.linux-samba.user}"
|
||||||
"password=${secrets.linux-samba.password}"
|
"password=${secrets.linux-samba.password}"
|
||||||
# "nofail"
|
|
||||||
"uid=${toString config.users.users.alukard.uid}"
|
"uid=${toString config.users.users.alukard.uid}"
|
||||||
"gid=${toString config.users.groups.users.gid}"
|
"gid=${toString config.users.groups.users.gid}"
|
||||||
|
"vers=3.0"
|
||||||
|
"nofail"
|
||||||
|
"noauto"
|
||||||
|
"x-systemd.automount"
|
||||||
|
"x-systemd.mount-timeout=15"
|
||||||
|
"_netdev"
|
||||||
];
|
];
|
||||||
|
# ] ++ lib.optionals wgEnabled [
|
||||||
|
# "x-systemd.after=wg-quick-wg0.service"
|
||||||
|
# ];
|
||||||
};
|
};
|
||||||
"/media/files" = if isHost then {
|
"/media/files" = if isHost then {
|
||||||
# Samba host
|
# Samba host
|
||||||
fsType = "ntfs";
|
fsType = "ntfs";
|
||||||
device = "/dev/disk/by-partuuid/8a1d933c-302b-4e62-b9af-a45ecd05777f";
|
device = "/dev/disk/by-partuuid/8a1d933c-302b-4e62-b9af-a45ecd05777f";
|
||||||
options = [
|
options = [
|
||||||
# "ro"
|
|
||||||
# "noatime"
|
# "noatime"
|
||||||
"nofail"
|
"nofail"
|
||||||
"uid=${toString config.users.users.alukard.uid}"
|
"uid=${toString config.users.users.alukard.uid}"
|
||||||
@ -60,10 +69,18 @@ with deviceSpecific; {
|
|||||||
options = [
|
options = [
|
||||||
"user=${secrets.linux-samba.user}"
|
"user=${secrets.linux-samba.user}"
|
||||||
"password=${secrets.linux-samba.password}"
|
"password=${secrets.linux-samba.password}"
|
||||||
# "nofail"
|
|
||||||
"uid=${toString config.users.users.alukard.uid}"
|
"uid=${toString config.users.users.alukard.uid}"
|
||||||
"gid=${toString config.users.groups.users.gid}"
|
"gid=${toString config.users.groups.users.gid}"
|
||||||
|
"vers=3.0"
|
||||||
|
"nofail"
|
||||||
|
"noauto"
|
||||||
|
"x-systemd.automount"
|
||||||
|
"x-systemd.mount-timeout=15"
|
||||||
|
"_netdev"
|
||||||
];
|
];
|
||||||
|
# ] ++ lib.optionals wgEnabled [
|
||||||
|
# "x-systemd.after=wg-quick-wg0.service"
|
||||||
|
# ];
|
||||||
};
|
};
|
||||||
# Samba Windows
|
# Samba Windows
|
||||||
"/media/windows/files" = lib.mkIf (!isHost) {
|
"/media/windows/files" = lib.mkIf (!isHost) {
|
||||||
@ -72,22 +89,37 @@ with deviceSpecific; {
|
|||||||
options = [
|
options = [
|
||||||
"user=${secrets.windows-samba.user}"
|
"user=${secrets.windows-samba.user}"
|
||||||
"password=${secrets.windows-samba.password}"
|
"password=${secrets.windows-samba.password}"
|
||||||
# "nofail"
|
|
||||||
"uid=${toString config.users.users.alukard.uid}"
|
"uid=${toString config.users.users.alukard.uid}"
|
||||||
"gid=${toString config.users.groups.users.gid}"
|
"gid=${toString config.users.groups.users.gid}"
|
||||||
|
"vers=3.0"
|
||||||
|
"nofail"
|
||||||
|
"noauto"
|
||||||
|
"x-systemd.automount"
|
||||||
|
"x-systemd.mount-timeout=15"
|
||||||
|
"_netdev"
|
||||||
];
|
];
|
||||||
|
# ] ++ lib.optionals wgEnabled [
|
||||||
|
# "x-systemd.after=wg-quick-wg0.service"
|
||||||
|
# ];
|
||||||
};
|
};
|
||||||
"/media/windows/data" = lib.mkIf (!isHost) {
|
"/media/windows/data" = lib.mkIf (!isHost) {
|
||||||
fsType = "cifs";
|
fsType = "cifs";
|
||||||
device = "//192.168.0.100/Data";
|
device = "//192.168.0.100/Data";
|
||||||
options = [
|
options = [
|
||||||
"ro"
|
|
||||||
"user=${secrets.windows-samba.user}"
|
"user=${secrets.windows-samba.user}"
|
||||||
"password=${secrets.windows-samba.password}"
|
"password=${secrets.windows-samba.password}"
|
||||||
# "nofail"
|
|
||||||
"uid=${toString config.users.users.alukard.uid}"
|
"uid=${toString config.users.users.alukard.uid}"
|
||||||
"gid=${toString config.users.groups.users.gid}"
|
"gid=${toString config.users.groups.users.gid}"
|
||||||
|
"vers=3.0"
|
||||||
|
"nofail"
|
||||||
|
"noauto"
|
||||||
|
"x-systemd.automount"
|
||||||
|
"x-systemd.mount-timeout=15"
|
||||||
|
"_netdev"
|
||||||
];
|
];
|
||||||
|
# ] ++ lib.optionals wgEnabled [
|
||||||
|
# "x-systemd.after=wg-quick-wg0.service"
|
||||||
|
# ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user