nixos/samba: add services.samba.smbd.enable option
This commit is contained in:
parent
ee6c8db585
commit
7a3bba220d
@ -98,6 +98,12 @@ in
|
||||
'';
|
||||
};
|
||||
|
||||
smbd.enable = mkOption {
|
||||
type = types.bool;
|
||||
default = true;
|
||||
description = lib.mdDoc "Whether to enable Samba's smbd daemon.";
|
||||
};
|
||||
|
||||
nmbd.enable = mkOption {
|
||||
type = types.bool;
|
||||
default = true;
|
||||
@ -193,7 +199,7 @@ in
|
||||
# Refer to https://github.com/samba-team/samba/tree/master/packaging/systemd
|
||||
# for correct use with systemd
|
||||
services = {
|
||||
samba-smbd = daemonService "smbd" "";
|
||||
samba-smbd = mkIf cfg.smbd.enable (daemonService "smbd" "");
|
||||
samba-nmbd = mkIf cfg.nmbd.enable (daemonService "nmbd" "");
|
||||
samba-winbindd = mkIf cfg.winbindd.enable (daemonService "winbindd" "");
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user