about summary refs log tree commit diff
path: root/hosts/common/server/samba.nix
blob: 7df989d3a127f30f8364750407b063ab6da7c509 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
{ config, pkgs, lib, ... }:

{
  services.samba = {
    enable = true;
    securityType = "user";
    extraConfig = ''
      workgroup = WORKGROUP
      server string = tahoe
      netbios name = tahoe
      security = user
      guest account = nobody
      mangled names = no
      client min protocol = SMB2
      map to guest = bad user
      ntlm auth = true
    '';
    shares = {
      music = {
        path = "/data/fast/music";
        browseable = "yes";
        "read only" = "yes";
        "guest ok" = "yes";
      };
      videos = {
        path = "/data/fast/videos";
        browseable = "yes";
        "read only" = "yes";
        "guest ok" = "yes";
      };
    };
  };
}