From cbc05c1480234a558df4b0b3bdc30a9f020d3b37 Mon Sep 17 00:00:00 2001
From: Eelco Dolstra <eelco.dolstra@logicblox.com>
Date: Sun, 8 Aug 2010 13:55:35 +0000
Subject: [PATCH] * Enable wpa_supplicant on the installation CD.

svn path=/nixos/trunk/; revision=23034
---
 modules/installer/cd-dvd/installation-cd-base.nix   | 5 ++++-
 modules/installer/cd-dvd/installation-cd-rescue.nix | 2 +-
 modules/installer/cd-dvd/live-dvd.nix               | 1 -
 3 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/modules/installer/cd-dvd/installation-cd-base.nix b/modules/installer/cd-dvd/installation-cd-base.nix
index 69089d600e4c..0fc7fa581a19 100644
--- a/modules/installer/cd-dvd/installation-cd-base.nix
+++ b/modules/installer/cd-dvd/installation-cd-base.nix
@@ -47,7 +47,6 @@ let
           pkgs.sshfsFuse
           pkgs.socat
           pkgs.screen
-          pkgs.wpa_supplicant # !!! should use the wpa module
 
           # Hardware-related tools.
           pkgs.sdparm
@@ -249,4 +248,8 @@ in
   # default root password is empty.
   services.openssh.enable = true;
   jobs.sshd.startOn = pkgs.lib.mkOverride 50 {} "";
+
+  # Enable wpa_supplicant, but don't start it by default.
+  networking.enableWLAN = true;
+  jobs.wpa_supplicant.startOn = pkgs.lib.mkOverride 50 {} "";
 }
diff --git a/modules/installer/cd-dvd/installation-cd-rescue.nix b/modules/installer/cd-dvd/installation-cd-rescue.nix
index fe067df03fbc..ed5184c69cb3 100644
--- a/modules/installer/cd-dvd/installation-cd-rescue.nix
+++ b/modules/installer/cd-dvd/installation-cd-rescue.nix
@@ -20,7 +20,7 @@
     utillinuxCurses ddrescue 
     pciutils sdparm hdparm hddtemp usbutils
     btrfsProgs xfsprogs jfsutils jfsrec
-    wpa_supplicant iproute 
+    iproute 
     fuse ntfs3g smbfsFuse sshfsFuse
     manpages irssi elinks mcabber mutt openssh lftp 
     openssl ncat socat
diff --git a/modules/installer/cd-dvd/live-dvd.nix b/modules/installer/cd-dvd/live-dvd.nix
index 655376fdea45..70fa301ef1fd 100644
--- a/modules/installer/cd-dvd/live-dvd.nix
+++ b/modules/installer/cd-dvd/live-dvd.nix
@@ -10,7 +10,6 @@
   # Include lots of packages.
   environment.systemPackages =
     [ pkgs.utillinuxCurses
-      pkgs.wpa_supplicant 
       pkgs.upstartJobControl
       pkgs.iproute
       pkgs.bc