mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-21 12:59:04 +02:00
* Don't include the hostname in option default values. Default values
are included in the manual, so this causes a different manual to be built for each machine. * Clean up indentation of cntlm module. svn path=/nixos/trunk/; revision=34387
This commit is contained in:
parent
6aa4120f3a
commit
87e06b97a3
|
@ -44,7 +44,7 @@ in
|
|||
};
|
||||
|
||||
hostName = mkOption {
|
||||
default = config.networking.hostName;
|
||||
type = types.uniq types.string;
|
||||
description = ''Host name advertised on the LAN.'';
|
||||
};
|
||||
|
||||
|
@ -93,6 +93,8 @@ in
|
|||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
services.avahi.hostName = mkDefault config.networking.hostName;
|
||||
|
||||
users.extraUsers = singleton
|
||||
{ name = "avahi";
|
||||
uid = config.ids.uids.avahi;
|
||||
|
|
|
@ -13,7 +13,7 @@ in
|
|||
|
||||
options = {
|
||||
|
||||
services.cntlm= {
|
||||
services.cntlm = {
|
||||
|
||||
enable = mkOption {
|
||||
default = false;
|
||||
|
@ -39,9 +39,9 @@ in
|
|||
};
|
||||
|
||||
netbios_hostname = mkOption {
|
||||
default = config.networking.hostName;
|
||||
type = types.uniq types.string;
|
||||
description = ''
|
||||
The hostname of your workstation.
|
||||
The hostname of your machine.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -73,28 +73,28 @@ in
|
|||
###### implementation
|
||||
|
||||
config = mkIf config.services.cntlm.enable {
|
||||
|
||||
services.cntlm.netbios_hostname = mkDefault config.networking.hostName;
|
||||
|
||||
users.extraUsers = singleton {
|
||||
name = "cntlm";
|
||||
description = "cntlm system-wide daemon";
|
||||
home = "/var/empty";
|
||||
name = "cntlm";
|
||||
description = "cntlm system-wide daemon";
|
||||
home = "/var/empty";
|
||||
};
|
||||
|
||||
jobs.cntlm = {
|
||||
description = "cntlm is an NTLM / NTLM Session Response / NTLMv2 authenticating HTTP proxy.";
|
||||
jobs.cntlm =
|
||||
{ description = "CNTLM is an NTLM / NTLM Session Response / NTLMv2 authenticating HTTP proxy";
|
||||
|
||||
startOn = "started network-interfaces";
|
||||
environment = {
|
||||
};
|
||||
|
||||
preStart = '' '';
|
||||
daemonType = "fork";
|
||||
|
||||
daemonType = "fork";
|
||||
|
||||
exec =
|
||||
''
|
||||
${pkgs.cntlm}/bin/cntlm -U cntlm \
|
||||
-c ${pkgs.writeText "cntlm_config" cfg.extraConfig}
|
||||
'';
|
||||
};
|
||||
exec =
|
||||
''
|
||||
${pkgs.cntlm}/bin/cntlm -U cntlm \
|
||||
-c ${pkgs.writeText "cntlm_config" cfg.extraConfig}
|
||||
'';
|
||||
};
|
||||
|
||||
services.cntlm.extraConfig =
|
||||
''
|
||||
|
@ -109,5 +109,7 @@ in
|
|||
Listen ${toString port}
|
||||
'') cfg.port}
|
||||
'';
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue