Fix smb cifs mount permissions & update flake deps

This commit is contained in:
Tristan D. 2023-12-04 12:20:48 +01:00
parent 57e91462ab
commit 0a36bfc203
Signed by: tristan
SSH key fingerprint: SHA256:U7y6eMb7CQDaTHv9XoX6/BaQnPqyxxKc+Xnfcefi6rY
2 changed files with 33 additions and 34 deletions

24
flake.lock generated
View file

@ -69,11 +69,11 @@
]
},
"locked": {
"lastModified": 1701334333,
"narHash": "sha256-rsJ11xznoc2JSmM57bstxyas8xq8ZaEqNhQuQWyoQ/A=",
"lastModified": 1701680013,
"narHash": "sha256-H8uAiSr//UhEdTTRDJwP6LCTq7d1sXF1IKpe8GDW3PA=",
"owner": "nix-community",
"repo": "emacs-overlay",
"rev": "913e44a13636fd111139ee683a6741ccb4c28672",
"rev": "1ff5471880b6e48f63ec5fa668486ab1268c2b22",
"type": "github"
},
"original": {
@ -318,11 +318,11 @@
},
"nixpkgs-unstable": {
"locked": {
"lastModified": 1701432845,
"narHash": "sha256-06sd2rQ+DPMSueh+hW4MiXbpMSdhQHJOi/sw0vuwqvs=",
"lastModified": 1701626906,
"narHash": "sha256-ugr1QyzzwNk505ICE4VMQzonHQ9QS5W33xF2FXzFQ00=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "77da99a144cd341408308e0a37622f5edcc6c5ba",
"rev": "0c6d8c783336a59f4c59d4a6daed6ab269c4b361",
"type": "github"
},
"original": {
@ -334,11 +334,11 @@
},
"nixpkgs_2": {
"locked": {
"lastModified": 1701389149,
"narHash": "sha256-rU1suTIEd5DGCaAXKW6yHoCfR1mnYjOXQFOaH7M23js=",
"lastModified": 1701539137,
"narHash": "sha256-nVO/5QYpf1GwjvtpXhyxx5M3U/WN0MwBro4Lsk+9mL0=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "5de0b32be6e85dc1a9404c75131316e4ffbc634c",
"rev": "933d7dc155096e7575d207be6fb7792bc9f34f6d",
"type": "github"
},
"original": {
@ -350,11 +350,11 @@
},
"nur": {
"locked": {
"lastModified": 1701623572,
"narHash": "sha256-NBxGAGL+NqUON+2g9SjPJzcBIgov0gCM8WT8mZM83Xg=",
"lastModified": 1701679481,
"narHash": "sha256-mwcnWs3hi6t2yf1xDAvQyN4p94B2AIK5tkXqgPm8/vk=",
"owner": "nix-community",
"repo": "NUR",
"rev": "805f936f3ce5589d53c2a2c5eeab4019a233e10d",
"rev": "946611806d877569dbcee22f39a92a59a137c7b1",
"type": "github"
},
"original": {

View file

@ -97,27 +97,26 @@
};
};
fileSystems."/mnt/ServerF" = {
fileSystems =
let
automount_opts = "x-systemd.automount,noauto,x-systemd.idle-timeout=60,x-systemd.device-timeout=5s,x-systemd.mount-timeout=5s";
perm_opts = "uid=1000,gid=100";
cifs_opts = "vers=2.0,credentials=/home/tristand/.smb-secrets";
mount_opts = "${automount_opts},${perm_opts},${cifs_opts}";
in
{
"/mnt/ServerF" = {
# device = "//srv-nas-01.local/Server_F";
device = "//192.168.0.1/Server_F";
fsType = "cifs";
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";
in
[ "${automount_opts},vers=2.0,credentials=/home/tristand/.smb-secrets" ];
options = [ mount_opts ];
};
fileSystems."/mnt/Scans" = {
"/mnt/Scans" = {
# device = "//srv-nas-01.local/Server_F";
device = "//192.168.0.1/Scans";
fsType = "cifs";
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";
in
[ "${automount_opts},vers=2.0,credentials=/home/tristand/.smb-secrets" ];
options = [ mount_opts ];
};
};
systemd = {