summary refs log tree commit diff
path: root/modules/services/networking/hostapd.nix
diff options
context:
space:
mode:
authorJack Cummings <jack@mudshark.org>2012-10-09 12:19:09 -0700
committerJack Cummings <jack@mudshark.org>2012-10-09 12:19:09 -0700
commit71e6eca5675a9a32d245ace3b29154409a4700bf (patch)
tree972f96a5b1f81dc26bb264638c8d37ca55af46cb /modules/services/networking/hostapd.nix
parent33754edb3e7cae6e54d85bb01fa0b5e228b283cf (diff)
downloadnixpkgs-71e6eca5675a9a32d245ace3b29154409a4700bf.tar
nixpkgs-71e6eca5675a9a32d245ace3b29154409a4700bf.tar.gz
nixpkgs-71e6eca5675a9a32d245ace3b29154409a4700bf.tar.bz2
nixpkgs-71e6eca5675a9a32d245ace3b29154409a4700bf.tar.lz
nixpkgs-71e6eca5675a9a32d245ace3b29154409a4700bf.tar.xz
nixpkgs-71e6eca5675a9a32d245ace3b29154409a4700bf.tar.zst
nixpkgs-71e6eca5675a9a32d245ace3b29154409a4700bf.zip
- fix indention, clarify parameter descriptions, and use 'exec' instead of 'script' in the hostapd job
Diffstat (limited to 'modules/services/networking/hostapd.nix')
-rw-r--r--modules/services/networking/hostapd.nix23
1 files changed, 12 insertions, 11 deletions
diff --git a/modules/services/networking/hostapd.nix b/modules/services/networking/hostapd.nix
index 712b1a6824c..42779494b4b 100644
--- a/modules/services/networking/hostapd.nix
+++ b/modules/services/networking/hostapd.nix
@@ -52,7 +52,7 @@ in
       enable = mkOption {
         default = false;
         description = ''
-          enable putting a wireless interface into infrastructure mode,
+          Enable putting a wireless interface into infrastructure mode,
           allowing other wireless devices to associate with the wireless interface and do
           wireless networking. A simple access point will enable hostapd.wpa, and
           hostapd.wpa_passphrase, hostapd.ssid, dhcpd on the wireless interface to
@@ -107,19 +107,24 @@ in
         example = "network";
         type = types.string;
         description = "members of this group can control hostapd";
-        };
+      };
 
       wpa = mkOption {
         default = true;
         description = "enable WPA (IEEE 802.11i/D3.0) to authenticate to the access point";
-        };
+      };
 
       wpaPassphrase = mkOption {
         default = "my_sekret";
         example = "any_64_char_string";
         type = types.string;
-        description = "WPA-PSK (pre-shared-key) passphrase. Clients will need this passphrase to associate with this access point";
-        };
+        description = 
+          ''
+          WPA-PSK (pre-shared-key) passphrase. Clients will need this
+          passphrase to associate with this access point. Warning: This passphrase will
+          get put into a world-readable file in the nix store. 
+          '';
+      };
 
       extraCfg = mkOption {
         default = "";
@@ -130,9 +135,9 @@ in
           '';
         type = types.string;
         description = "Extra configuration options to put in the hostapd.conf";
-        };
       };
     };
+  };
 
 
   ###### implementation
@@ -144,11 +149,7 @@ in
     jobs.hostapd =
       { startOn = "started network-interfaces";
         stopOn = "stopping network-interfaces";
-
-        script =
-          ''
-            exec ${pkgs.hostapd}/bin/hostapd ${configFile}
-          '';
+        exec = "${pkgs.hostapd}/bin/hostapd ${configFile}";
       };
   };
 }