-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
120657d
commit 1db22c4
Showing
3 changed files
with
58 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -57,3 +57,4 @@ | |
}; | ||
} | ||
# vim: filetype=nix | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,38 @@ | ||
{ config, lib, pkgs, ... }: { | ||
services = { | ||
samba = { | ||
package = pkgs.samba4Full; | ||
enable = true; | ||
openFirewall = true; | ||
shares.testshare = { | ||
# !TODO: get the current user | ||
path = "/home/glwbr/"; | ||
writable = "true"; | ||
comment = "This is a test!"; | ||
}; | ||
extraConfig = '' | ||
server smb encrypt = required | ||
# ^^ Note: Breaks `smbclient -L <ip/host> -U%` by default, might require the client to set `client min protocol`? | ||
server min protocol = SMB3_00 | ||
''; | ||
}; | ||
avahi = { | ||
publish.enable = true; | ||
publish.userServices = true; | ||
# ^^ Needed to allow samba to automatically register mDNS records (without the need for an `extraServiceFile` | ||
#nssmdns4 = true; | ||
enable = true; | ||
openFirewall = true; | ||
}; | ||
samba-wsdd = { | ||
# This enables autodiscovery on windows since SMB1 (and thus netbios) support was discontinued | ||
enable = true; | ||
openFirewall = true; | ||
{ | ||
config, | ||
lib, | ||
pkgs, | ||
... | ||
}: { | ||
services = { | ||
samba = { | ||
package = pkgs.samba4Full; | ||
enable = true; | ||
openFirewall = true; | ||
shares.testshare = { | ||
# !TODO: get the current user | ||
path = "/home/glwbr/"; | ||
writable = "true"; | ||
comment = "This is a test!"; | ||
}; | ||
extraConfig = '' | ||
server smb encrypt = required | ||
# ^^ Note: Breaks `smbclient -L <ip/host> -U%` by default, might require the client to set `client min protocol`? | ||
server min protocol = SMB3_00 | ||
''; | ||
}; | ||
avahi = { | ||
publish.enable = true; | ||
publish.userServices = true; | ||
# ^^ Needed to allow samba to automatically register mDNS records (without the need for an `extraServiceFile` | ||
#nssmdns4 = true; | ||
enable = true; | ||
openFirewall = true; | ||
}; | ||
samba-wsdd = { | ||
# This enables autodiscovery on windows since SMB1 (and thus netbios) support was discontinued | ||
enable = true; | ||
openFirewall = true; | ||
}; | ||
}; | ||
} |