Commit graph

598 commits

Author SHA1 Message Date
Eelco Dolstra dff372db3c * Fix evaluation of the luksroot module when luksRoot == null. The
problem is that configuration values below a mkIf are evaluated
  strictly even if the condition is false.  Thus "${luksRoot}" causes
  an evaluation error.  As a workaround, use the empty string instead
  of `null' as the default value.  However, we should really fix the
  laziness of mkIf.  It's likely that NixOS evaluation would be much
  faster if it didn't have to evaluate disabled configuration values.

svn path=/nixos/trunk/; revision=24477
2010-10-25 22:21:51 +00:00
Evgeny Egorochkin 791c758b41 Encrypted root support via LUKS
svn path=/nixos/trunk/; revision=24459
2010-10-25 00:57:30 +00:00
Eelco Dolstra cda2e41c01 * Added a "xendomains" job to automatically start the domains defined
in /etc/xen/auto at boot time, to save all running domains during
  shutdown, and to restore all saved domains at boot time.

svn path=/nixos/trunk/; revision=24121
2010-10-06 16:07:16 +00:00
Eelco Dolstra aeb89fc753 * Set /proc/sys/kernel/poweroff_cmd to Upstart's poweroff command
(rather than /sbin/poweroff).  Xen's "xm shutdown" needs this to
  enable the host to cleanly shutdown the guest.

svn path=/nixos/trunk/; revision=24094
2010-10-05 17:58:58 +00:00
Eelco Dolstra 8a6fad83f4 * Add a job attribute (path) to allow adding packages to the job's
$PATH environment variable.

svn path=/nixos/trunk/; revision=23780
2010-09-14 11:22:17 +00:00
Eelco Dolstra c4f910f550 * Substitute the path of the system derivation directly in the stage 2
init script.  This removes the need for the `systemConfig' boot
  parameter; `init=<stage-2-init>' is enough.  However, the GRUB menu
  builder still needs to add `systemConfig' to the kernel command line
  for compatibility with old configurations.

svn path=/nixos/trunk/; revision=23775
2010-09-13 22:10:25 +00:00
Eelco Dolstra 4046056cdc * In the activation script, don't require the path to the "system"
derivation on the command line.

svn path=/nixos/trunk/; revision=23770
2010-09-13 18:19:15 +00:00
Eelco Dolstra c8d1774f09 * Speed up the initialisation of /etc in the activation script a lot
by doing it in Perl instead of in Bash.  Forking a zillion times is
  slow.

svn path=/nixos/trunk/; revision=23766
2010-09-13 17:26:42 +00:00
Eelco Dolstra f729f12e4e Some cleanups in the activation script:
* Moved some scriptlets to the appropriate modules.
* Put the scriptlet that sets the default path at the start, since it
  never makes sense not to have it there.  It no longer needs to be
  declared as a dependency.
* If a scriptlet has no dependencies, it can be denoted as a plain
  string (i.e., `noDepEntry' is not needed anymore).

svn path=/nixos/trunk/; revision=23762
2010-09-13 15:41:38 +00:00
Eelco Dolstra c1295661c4 * Added a command `nixos-rebuild build-vm-with-bootloader'. This is
like `build-vm', but boots using the regular boot loader (i.e. GRUB
  1 or 2) rather than booting directly from the kernel/initrd.  Thus
  it allows testing of GRUB.

svn path=/nixos/trunk/; revision=23747
2010-09-13 12:34:58 +00:00
Eelco Dolstra 987dd76811 * Added a module to enable the Xen hypervisor.
svn path=/nixos/trunk/; revision=23739
2010-09-12 22:43:45 +00:00
Eelco Dolstra 6258845b61 svn path=/nixos/trunk/; revision=23727 2010-09-10 15:25:58 +00:00
Nicolas Pierron c9dc3651da Replace mkOverride by its alias mkOverrideTemplate to remove the unused
template argument of mkOverride later.

svn path=/nixos/trunk/; revision=23631
2010-09-03 19:10:59 +00:00
Eelco Dolstra f1a6a8b6e0 svn path=/nixos/trunk/; revision=23614 2010-09-03 11:39:48 +00:00
Eelco Dolstra f067d179ab * Create /nix/var/nix/gcroots/tmp in the activation script. The
build hook uses this directory to store temporary GC roots.  (It
  creates it if it doesn't exist, but it's better to do it here as
  well to ensure the right ownership and permissions.)
* Clear /nix/var/nix/gcroots/tmp and /nix/var/nix/temproots at boot
  time.

svn path=/nixos/trunk/; revision=23417
2010-08-25 11:59:04 +00:00
Eelco Dolstra 3f10cf70f6 * Regression test for the build hook mechanism.
svn path=/nixos/trunk/; revision=23395
2010-08-24 13:27:28 +00:00
Lluís Batlle i Rossell fe2f7eae17 Making the stage1 work on mips too (for the name of the dynamic loader)
svn path=/nixos/trunk/; revision=23325
2010-08-21 18:23:55 +00:00
Michael Raskin 295df77f21 Move resume section after udev launch - on some systems devices are recognized by kernel only after udev works.
svn path=/nixos/trunk/; revision=23176
2010-08-14 20:12:05 +00:00
Eelco Dolstra 313629adcf * Add ext4 to the default initrd.
svn path=/nixos/trunk/; revision=23088
2010-08-10 10:12:18 +00:00
Eelco Dolstra e41e6a65bb * Make sure that /tmp/.ICE-unix is owned by root and has 1777
permissions.  Otherwise it ends up being owned by the first user to
  log in, and other users' iceauth calls fail.

svn path=/nixos/trunk/; revision=23052
2010-08-09 10:59:20 +00:00
Eelco Dolstra e8e7ee356c * In the installation CD, pass the label of the CD through the
root=... kernel command line parameter, instead of hard-coding it in
  `fileSystems'.  This is to allow CD-to-USB converters such as
  UNetbootin to rewrite the kernel command line to the label or UUID
  of the USB stick.

svn path=/nixos/trunk/; revision=23024
2010-08-07 14:16:18 +00:00
Eelco Dolstra 21e62884e7 * switch-to-configuration.sh: Signal dbus to reload its configuration.
svn path=/nixos/trunk/; revision=22718
2010-07-23 10:52:51 +00:00
Evgeny Egorochkin 88a400f578 Fix LVM failing test due to /proc/devices not being available in some of OpenVZ containers
svn path=/nixos/trunk/; revision=22717
2010-07-22 22:45:24 +00:00
Eelco Dolstra d659488209 * Use the regular GRUB menu builder for Amazon. There are two issues:
we want to generate the GRUB menu without actually installing GRUB
  (because Amazon supplies its own pv-grub), and each menu entry
  requires "root (hd0)".  For the first, allow boot.loader.grub.device
  to be set to "nodev" to indicate that the GRUB menu should be
  generated without installing GRUB.  For the second, add an option
  boot.loader.grub.extraPerEntryConfig to allow commands to be added
  to each GRUB menu entry (in this case, "root (hd0)").

svn path=/nixos/trunk/; revision=22712
2010-07-22 14:40:29 +00:00
Eelco Dolstra e7c0c929ed * Work around a bug in QEMU, which doesn't implement the "READ DISC
INFORMATION" SCSI command:

    https://bugzilla.redhat.com/show_bug.cgi?id=609049

  As a result, `cdrom_id' doesn't print
  ID_CDROM_MEDIA_TRACK_COUNT_DATA, which in turn prevents the
  /dev/disk/by-label symlinks from being created.  We need these in
  the NixOS installation CD, so use ID_CDROM_MEDIA in the
  corresponding udev rules for now.  This was the behaviour in udev <=
  154.  See also
       
    http://www.spinics.net/lists/hotplug/msg03935.html

svn path=/nixos/trunk/; revision=22691
2010-07-21 21:15:54 +00:00
Eelco Dolstra 1b04d3a813 * Absolutise $systemConfig in case it's a symlink.
svn path=/nixos/trunk/; revision=22677
2010-07-20 13:50:10 +00:00
Eelco Dolstra 63962dd7d6 * Disable the test to see whether $stage2Init exists. For some
unfathomable reason this test fails on EC2 if it's a symlink
  (despite the -L test).  I give up.

svn path=/nixos/trunk/; revision=22676
2010-07-20 13:49:04 +00:00
Eelco Dolstra b14f80c89a * The modprobe wrapper nowadays checks whether the version of the
current kernel module tree matches the booted kernel, so it should
  be safe to use after an upgrade.

svn path=/nixos/trunk/; revision=22627
2010-07-18 20:19:27 +00:00
Eelco Dolstra f3e1607758 * Don't run the emergency-shell task after nixos-rebuild because it
screws up the X server (CPU usage goes to 100%, switching virtual
  consoles no longer works, etc.).  TODO: we need some generic way to
  mark jobs that shouldn't be started automatically.

svn path=/nixos/trunk/; revision=22608
2010-07-15 12:31:18 +00:00
Eelco Dolstra bfe46a653b * Mount /dev, /proc and /sys when booting without a stage 1 (e.g. on
Amazon).

svn path=/nixos/trunk/; revision=22598
2010-07-14 10:55:45 +00:00
Eelco Dolstra 54a4eead20 * Typos.
svn path=/nixos/trunk/; revision=22537
2010-07-08 16:21:55 +00:00
Eelco Dolstra b076121430 * Don't use the -v flag because not every fsck backend knows it.
svn path=/nixos/trunk/; revision=22512
2010-07-07 14:25:16 +00:00
Eelco Dolstra d43d321e86 * Sync with the trunk.
svn path=/nixos/branches/boot-order/; revision=22349
2010-06-20 20:54:31 +00:00
Eelco Dolstra 69c7175404 * During shutdown, don't unmount mount points that don't exist (in the
current namespace).  This prevents warnings about the aufs/tmpfs
  mounts from the initrd used by the installation CD.

svn path=/nixos/branches/boot-order/; revision=22299
2010-06-16 22:16:43 +00:00
Eelco Dolstra a5c433696c * Put all of /var/run (not just /var/run/nscd) on a tmpfs to simplify
shutdown.  (Portmap and statd are needed during shutdown to unmount
  NFS volumes but have open files in /var/run.)
* In the shutdown job, don't kill PIDs belonging to Upstart jobs that
  are still running.  If they don't stop on the "starting shutdown"
  event, then they're needed during shutdown (such as portmap and
  statd).
* NFS test: test whether the shutdown quickly unmounts NFS volumes
  (i.e. whether portmap and statd are still running).

svn path=/nixos/branches/boot-order/; revision=22204
2010-06-09 22:29:06 +00:00
Eelco Dolstra 3eac003800 * Maintain /var/log/wtmp correctly during boot/shutdown.
svn path=/nixos/branches/boot-order/; revision=22182
2010-06-08 12:48:16 +00:00
Eelco Dolstra 7c3ae9e716 * During shutdown, warn explicitly about filesystems that could not be
unmounted or remounted read-only.
* Don't try to unmount / or /nix/store.

svn path=/nixos/branches/boot-order/; revision=22181
2010-06-08 11:52:16 +00:00
Eelco Dolstra 23cc979f61 * Run `swapoff -a' during shutdown. Otherwise filesystems containing
swapfiles cannot be unmounted or even remounted read-only.
* In the remount, pass `-t none' to get a more informative error
  message if the filesystem is in use.

svn path=/nixos/branches/boot-order/; revision=22179
2010-06-08 10:06:00 +00:00
Eelco Dolstra c089738bdc * Use the shadow' package instead of pwdutils', `pam_login' and
`su'.
* The `usermod' from `shadow' allows setting a supplementary group
  equal to the user's primary group, so the special hack for the
  `nixbld' group is no longer needed.
* Removed /etc/default/passwd since it's not used by the new passwd.
  The hash is configured in pam_unix.
* Move some values for `security.setuidPrograms' and
  `security.pam.services' to the appropriate modules.

svn path=/nixos/trunk/; revision=22107
2010-06-02 21:10:48 +00:00
Eelco Dolstra 8b308272df * We don't use pam_console anymore.
svn path=/nixos/trunk/; revision=22104
2010-06-02 17:11:20 +00:00
Eelco Dolstra ad93acc295 * Make all Upstart jobs shut down on the `starting shutdown' event.
This ensures that they're gone by the time the shutdown job runs, so
  it doesn't have to stop them itself.
* Don't respawn tasks, as it doesn't seem useful (if they fail they're
  likely to fail again if they're restarted).

svn path=/nixos/trunk/; revision=22099
2010-06-02 16:04:08 +00:00
Eelco Dolstra 94b2268192 * Start "exec" jobs using the "script" stanza to allow redirects in
the job's "exec" to work properly.

svn path=/nixos/trunk/; revision=22094
2010-06-01 20:41:59 +00:00
Eelco Dolstra 95a9c5dd77 * Log the standard output/error of Upstart jobs to
/var/log/upstart/<jobname> rather than spamming the console with it.

svn path=/nixos/trunk/; revision=22093
2010-06-01 19:44:23 +00:00
Eelco Dolstra 18fd0a61de * Add `sleep' to the initrd.
svn path=/nixos/trunk/; revision=22089
2010-06-01 17:09:34 +00:00
Eelco Dolstra 9c900ee15c * Updates for the dynamically linked splash helper.
svn path=/nixos/trunk/; revision=22087
2010-06-01 16:38:42 +00:00
Eelco Dolstra dc49a0ce3f * Don't use klibc in the initrd. It's simpler (and slightly smaller)
to use the standard (coreutils) tools.
* Use util-linux's `switch_root' to switch over to the target root
  FS.  It automatically moves over the /dev, /proc and /sys from stage
  1, so stage 2 doesn't need to set them up again.

svn path=/nixos/trunk/; revision=22085
2010-06-01 15:53:24 +00:00
Eelco Dolstra eade772338 * Don't show the contents of linuxPackages in the manual.
svn path=/nixos/trunk/; revision=22044
2010-05-28 11:21:40 +00:00
Eelco Dolstra 7484774172 * Activate software RAID devices from udev. This makes the swraid
Upstart jobs unnecessary.
* Support having the root filesystem on swraid.

svn path=/nixos/trunk/; revision=21807
2010-05-16 20:40:04 +00:00
Eelco Dolstra edee370883 * The default action for udevadm trigger' changed from add' to
`change'.  At boot time, however, we want an `add' event to trigger
  certain rules (e.g. LVM and mdadm).

svn path=/nixos/trunk/; revision=21804
2010-05-16 19:02:45 +00:00
Yury G. Kudryashov 7836f89242 stage-1.nix: copy libudev.so, verbose log
svn path=/nixos/trunk/; revision=21793
2010-05-15 21:28:31 +00:00
Nicolas Pierron 06bfb319fe Add extra module argument to provide a nesting.clone option. This option
does the same as nesting.children except that each configuration inherits
from the top-level configuration.

svn path=/nixos/trunk/; revision=21663
2010-05-08 17:18:26 +00:00
Marc Weber 6daed6b8d2 setting default of copySystemConfiguration to false.
http://thread.gmane.org/gmane.linux.distributions.nixos/3990

svn path=/nixos/trunk/; revision=21450
2010-04-30 07:43:29 +00:00
Marc Weber d1e87dfc86 adding two new options:
- system.copySystemConfiguration (requested by Ludovic Courtès)
- system.extraSystemBuilderCmds

svn path=/nixos/trunk/; revision=21406
2010-04-28 14:55:26 +00:00
Yury G. Kudryashov a5718503e5 Change firmware handling
This way should work with both old udev and new one.

svn path=/nixos/trunk/; revision=21308
2010-04-25 18:26:56 +00:00
Lluís Batlle i Rossell a37743794d I forgot a 'toString' in front of an integer
svn path=/nixos/trunk/; revision=21242
2010-04-22 14:54:09 +00:00
Lluís Batlle i Rossell d7406769ac Making /var/run/utmp writable by the 'utmp' group.
Then, people can choose a setgid utmp for their xterm, konsole or whatever to get the terminals
reported there.


svn path=/nixos/trunk/; revision=21238
2010-04-22 13:56:26 +00:00
Lluís Batlle i Rossell 33ed225a84 Making the /dev and /dev/shm tmpfs sizes configurable.
By default, they take the usual value of "50% of physical RAM".

As /dev/shm can be filled by anyone, and tmpfs does not trigger the OOM killer (and
can hang the machine due to a lack of RAM), I need to configure that down
in order to avoid crashes.

There is still left the /var/run/nscd tmpfs filesystem, also created with 50%
of the RAM, but at least not writeable by anyone. We could find a reasonable
low value for that, or allow configuration.


svn path=/nixos/trunk/; revision=21140
2010-04-17 15:20:13 +00:00
Yury G. Kudryashov 1e83fe6122 Remove tabs
svn path=/nixos/trunk/; revision=21104
2010-04-15 15:47:26 +00:00
Sander van der Burg 02e4a78c71 Disnix should also remain active during a switch
svn path=/nixos/trunk/; revision=20949
2010-04-05 20:35:08 +00:00
Eelco Dolstra c1e313b5e1 * Remove obsolete references to kernelPackages in Nixpkgs.
svn path=/nixos/trunk/; revision=20647
2010-03-16 12:10:06 +00:00
Eelco Dolstra 5b5aefa030 * Remove some obsolete stuff.
svn path=/nixos/trunk/; revision=20631
2010-03-15 13:41:21 +00:00
Eelco Dolstra 4253490fd4 svn path=/nixos/trunk/; revision=20016 2010-02-15 15:55:54 +00:00
Eelco Dolstra 0432766399 * Fall back to the kernel modules used at boot time if the modules in
the current configuration don't match the running kernel.  This
  ensures that modprobe still works after a "nixos-rebuild switch" to
  a configuration that has a different kernel version.

svn path=/nixos/trunk/; revision=19696
2010-01-26 21:45:13 +00:00
Marc Weber aad3d21ceb upstart: quote environment vars. John Altobelli hit the case TZ=New York
svn path=/nixos/trunk/; revision=19633
2010-01-23 22:38:30 +00:00
Eelco Dolstra 12a0a68749 * Initialise the Nix database in the VM.
* Set the hostname at startup.
* Mount the ephemeral data disk (/dev/sda2).


svn path=/nixos/trunk/; revision=19619
2010-01-22 17:31:23 +00:00
Eelco Dolstra 6d21e00776 * Some hacks to support running NixOS on Amazon EC2 (and other hosting
environment where you don't get to run stage 1 of the boot).

svn path=/nixos/trunk/; revision=19579
2010-01-20 18:06:33 +00:00
Michael Raskin 6502806689 Allow turning off VESA framebuffer
svn path=/nixos/trunk/; revision=19473
2010-01-15 21:55:51 +00:00
Lluís Batlle i Rossell 13ee735395 Making nixos work well with the new names 'linuxPackages' in stdenv-updates, additionally
to the nixpkgs trunk 'kernelPackages'.
Seeing a strange kernelPackages mentioned in installation-cd-rescue (2.6.31_something) I
update that to 2.6.32.


svn path=/nixos/trunk/; revision=19443
2010-01-14 19:50:49 +00:00
Eelco Dolstra ee005424bf * Doh, subtle race condition: STARTUP must be cleared after "udevadm
settle".  Otherwise some rules may be processed with STARTUP
  cleared, causing LVM devices not to be created.

svn path=/nixos/trunk/; revision=19341
2010-01-10 20:08:35 +00:00
Eelco Dolstra ac8a2ae577 * Use the LVM udev rules in stage 1. This makes
/dev/disk/by-{label,uuid} paths available for LVM volumes.

svn path=/nixos/trunk/; revision=19334
2010-01-10 19:00:29 +00:00
Eelco Dolstra e50a7e5f32 * Removed the boot.initrd.lvm option for simplicity.
svn path=/nixos/trunk/; revision=19330
2010-01-10 16:32:30 +00:00
Eelco Dolstra 39796e26b4 * Removed the boot.isLiveCD option. Moved the code for mounting a
tmpfs on top of the CD to iso-image.nix.

svn path=/nixos/trunk/; revision=19318
2010-01-09 15:13:06 +00:00
Lluís Batlle i Rossell b59cfde311 Making /dev/pts files have group owner 'tty', so 'mesg y' will work.
svn path=/nixos/trunk/; revision=19317
2010-01-09 14:23:20 +00:00
Eelco Dolstra 0595b7f89d * devicemapper -> lvm2.
svn path=/nixos/trunk/; revision=19294
2010-01-07 16:14:50 +00:00
Marc Weber fdc63c54e4 enhance phpIni documentation
readd r19267 (the issue should be fixed now)

Eelco Dolstra and Nicolas Pierron both kept asking me to pay attention
to the rendered manual. There is one catch: example settings such as
pkgs.kernelPackages_2_6_25 are correct however they don't render
properly. Moreover you don't want those examples to be evaluated (maybe
compiling a kernel ?) when building the manual only.
So use Strings and add a copy & paste note.
This is still a hacky. Maybe a kind of typed "verbatim" expression
should be added (?)

svn path=/nixos/trunk/; revision=19281
2010-01-07 09:01:40 +00:00
Eelco Dolstra c9e4b46d48 * Ugly hack: for CIFS mounts, retry the mount a few times (just as in
pkgs/build-support/vm).  This should make the NixOS regression tests
  more robust on heavily loaded systems, where they now frequently
  fail:

  server# mounting //10.0.2.4/qemu on /hostfs...
  server# [    8.233991] Slow work thread pool: Starting up
  server# [    8.234721] Slow work thread pool: Ready
  server# [   23.271708]  CIFS VFS: No response for cmd 114 mid 1
  server# [   23.272443]  CIFS VFS: cifs_mount failed w/return code = -112
  server# mount: Host is down
  server# [   23.275188] Kernel panic - not syncing: Attempted to kill init!

  Maybe there is a configurable timeout somewhere, which would be much
  nicer...

svn path=/nixos/trunk/; revision=19248
2010-01-06 00:25:14 +00:00
Eelco Dolstra 9889d9f9f8 * Remove most default kernel options since they have no effect. Also,
don't put them in a default, so that they can easily be added to.

svn path=/nixos/trunk/; revision=19232
2010-01-05 13:11:12 +00:00
Eelco Dolstra 170331be30 * Don't use /hostfs to signal the test driver that a VM is up, but
write some magic string to ttyS0.  This removes the dependency on
  having a CIFS mount.
* Use a thread to process the stdout/stderr of each QEMU instance.
* Add a kernel command line parameter "stage1panic" to tell stage 1 to
  panic if an error occurs.  This is faster than waiting until
  connect() times out.

svn path=/nixos/trunk/; revision=19212
2010-01-04 18:04:57 +00:00
Eelco Dolstra 01491abbfa * Handle the case where initScriptBuilder is not set.
svn path=/nixos/trunk/; revision=19014
2009-12-17 12:35:58 +00:00
Marc Weber 4ff6821a03 module creating /sbin/init
svn path=/nixos/trunk/; revision=19009
2009-12-17 06:04:36 +00:00
Lluís Batlle i Rossell 483ee6219e Fixing the shutdown script, for the not-that-strange case of having
/nix bind mounted from a fs not rootfs.

As niksnut found, if the sources of bind mounted directories are
umounted before remounting them as "ro", a "mount -o remount,ro" on the
bind targets will not leave the filesystem properly umounted, the same
way as a "-o remount,ro" would do on a usual filesystem.

So, the trick of always remounting as 'ro' before attempting an umount seems
to fix the problem.

svn path=/nixos/trunk/; revision=19008
2009-12-16 23:59:05 +00:00
Lluís Batlle i Rossell eea026d321 Enabling back the i8042 module loading at initrd. Otherwise, some
may not get any keyboard driver loaded (as I experienced).

svn path=/nixos/trunk/; revision=19006
2009-12-16 23:45:10 +00:00
Eelco Dolstra 8d588424d2 * switch-to-configuration: force a reinstallation of GRUB whenever the
GRUB version changes.  (That's the complete version from the name
  attribute, not the boot.loader.grub.version attribute.)  The current
  version is recorded in /boot/grub/version.  This is required to
  prevent massive breakage when we change the default value of
  boot.loader.grub.version to "2".

svn path=/nixos/trunk/; revision=18997
2009-12-16 18:11:26 +00:00
Eelco Dolstra daa814980e * At the end of stage 1, reset /proc/sys/kernel/modprobe to
/sbin/modprobe because the sactivation script in stage 2 expects it
  to be so.

svn path=/nixos/trunk/; revision=18977
2009-12-15 18:31:21 +00:00
Eelco Dolstra 6c9059e717 * Added an option `boot.initrd.availableKernelModules' that specifies
modules that should be added to the initrd, but should only be
  loaded on demand (e.g. by the kernel or by udev).  This is
  especially useful in the installation CD, where we now only load the
  modules needed by the hardware.
* Enable automatic modprobing by udev in the initrd.

svn path=/nixos/trunk/; revision=18975
2009-12-15 16:38:20 +00:00
Eelco Dolstra e8372257a1 * Reformat.
svn path=/nixos/trunk/; revision=18970
2009-12-15 14:10:06 +00:00
Eelco Dolstra a612fd0d5e * Obsoleted boot.initrd.extraKernelModules (use
boot.initrd.kernelModules instead).

svn path=/nixos/trunk/; revision=18969
2009-12-15 14:05:01 +00:00
Eelco Dolstra d6108919b1 * The loopback device is in a module now. Since it's not
automatically loaded by the kernel, load it at boot time.
* Put the ext2 module (which used to be built in) in the initrd to
  prevent unexpected breakage.

svn path=/nixos/trunk/; revision=18963
2009-12-15 13:09:06 +00:00
Marc Weber 4d7e344f69 Adding initial version of the nixos cd insallation test script using
qemu_kvm. Installation doesn't take place yet. VM is started
printing a remote controlled "Hello".

This serves as example how to run a vm within a bulid job.

svn path=/nixos/trunk/; revision=18887
2009-12-11 00:51:13 +00:00
Eelco Dolstra 38aeb2fdc8 svn path=/nixos/trunk/; revision=18860 2009-12-09 19:35:59 +00:00
Eelco Dolstra f26080c5f4 * Clean up the nixos-rebuild output a bit.
svn path=/nixos/trunk/; revision=18859
2009-12-09 18:23:48 +00:00
Nicolas Pierron 82a891dc46 Add support for require attributes inside children configurations.
svn path=/nixos/trunk/; revision=18820
2009-12-05 19:21:57 +00:00
Eelco Dolstra 8e8b3f9313 * Mount /var/run/nscd only once.
svn path=/nixos/branches/upstart-0.6/; revision=18607
2009-11-24 17:25:35 +00:00
Eelco Dolstra 9174b4ab42 * Provide a convience option for commands that must be executed both
when the system boots and when it resumes from suspend.

svn path=/nixos/branches/upstart-0.6/; revision=18354
2009-11-15 12:56:40 +00:00
Eelco Dolstra d1bbe706a2 * Synced with the trunk.
svn path=/nixos/branches/upstart-0.6/; revision=18297
2009-11-08 21:27:53 +00:00
Lluís Batlle i Rossell de1713a24f Failing when the top level system expression cannot find the kernel image
svn path=/nixos/trunk/; revision=18291
2009-11-08 18:32:21 +00:00
Eelco Dolstra 37470cccc5 * Blacklist the "evbug" module.
svn path=/nixos/trunk/; revision=18285
2009-11-08 09:08:50 +00:00
Eelco Dolstra 16c2aa734f * Generate /etc/modprobe.conf to allow the setting of module options
and the blacklisting of modules.

svn path=/nixos/trunk/; revision=18284
2009-11-08 09:01:53 +00:00
Eelco Dolstra 9bf8801dc6 * Use a tmpfs for /var/run/nscd to ensure that / or /var can be
unmounted or at least remounted read-only during shutdown.  Upstart
  0.6 apparently uses nscd to do some name lookups, resulting in it
  holding some mmap mappings to deleted files in /var/run/nscd.
  E.g. lsof shows:

    init         1 root  DEL       REG              253,0          1850313 /var/run/nscd/dbyn3Piz
    init         1 root  DEL       REG              253,0          1850312 /var/run/nscd/dbt2e8PH

  See also http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=324900.
  This is a workaround - it would be better if Upstart didn't do this.

svn path=/nixos/branches/upstart-0.6/; revision=18258
2009-11-07 15:29:46 +00:00
Eelco Dolstra 2353e53c5f * /var/run/safemode isn't used anywhere.
svn path=/nixos/branches/upstart-0.6/; revision=18257
2009-11-07 15:24:59 +00:00
Eelco Dolstra b7c519456e * Updated switch-to-configuration for Upstart 0.6.
svn path=/nixos/branches/upstart-0.6/; revision=18237
2009-11-07 01:17:56 +00:00
Eelco Dolstra d7342c78d4 * Support pre-stop scripts. These are needed to cleanly shutdown
daemons such as Apache or PostgreSQL.

svn path=/nixos/branches/upstart-0.6/; revision=18234
2009-11-06 22:45:19 +00:00
Eelco Dolstra 6b0842ff52 svn path=/nixos/branches/upstart-0.6/; revision=18229 2009-11-06 21:51:28 +00:00
Eelco Dolstra d545d08461 * In the network-interfaces task, emit an ip-up event if there is a
statically configured interface (i.e. we're not running dhclient).
  Otherwise the ntpd job won't be triggered.
* Use the "-n" flag of "initctl emit" to send the event
  asynchronously.

svn path=/nixos/branches/upstart-0.6/; revision=18227
2009-11-06 21:38:40 +00:00
Eelco Dolstra 4b2ff53ec6 * Don't stop jobs that are already stopped.
svn path=/nixos/branches/upstart-0.6/; revision=18226
2009-11-06 21:17:11 +00:00
Eelco Dolstra 82c3e2aa50 * Updated poweroff/reboot/maintenance mode for Upstart 0.6. Upstart
no longer emits specific events for those.  Instead it emits a
  "runlevel" event.  The "runlevel" task starts the "shutdown" task to
  perform the desired action.
* Upstart 0.6 no longer has a "shutdown" event, so "stop on shutdown"
  no longer works.  Therefore the shutdown task explicitly stops all
  running Upstart jobs, before sending a TERM/KILL signal to all
  remaining processes.
* Do a "chvt 1" at the start of the shutdown task to switch to the
  console.
* Use /dev/console instead of /dev/tty1, since if somebody is logged
  in on tty1, bad things will happen.

svn path=/nixos/branches/upstart-0.6/; revision=18224
2009-11-06 21:08:06 +00:00
Eelco Dolstra 676da4d87d * Updated some more jobs.
svn path=/nixos/branches/upstart-0.6/; revision=18219
2009-11-06 19:20:09 +00:00
Eelco Dolstra b9bfe7ed43 * Connect Upstart to the system bus.
svn path=/nixos/branches/upstart-0.6/; revision=18213
2009-11-06 15:59:23 +00:00
Eelco Dolstra 9fa2f12cc2 * Do some more jobs.
svn path=/nixos/branches/upstart-0.6/; revision=18212
2009-11-06 15:46:56 +00:00
Eelco Dolstra 903e92bde6 * Use Upstart's "export fork" feature to properly detect when a daemon
is "ready".  This prevents ugly race conditions, e.g. HAL failing to
  start because dbus hasn't finished starting yet.
* Support post-start scripts.  These are executed after the job's main
  process has started but before the job's "started" event is
  emitted.  For instance, the udev job uses this to perform "udevadm
  trigger / settle" to create all devices.  Previously this had to be
  done in the pre-start script, so the daemon had to started in the
  pre-start script as well.

svn path=/nixos/branches/upstart-0.6/; revision=18211
2009-11-06 15:23:16 +00:00
Eelco Dolstra 7011a9315f * Use Upstart 0.6. Jobs are now in /etc/init instead of /etc/event.d.
svn path=/nixos/branches/upstart-0.6/; revision=18192
2009-11-06 10:43:38 +00:00
Eelco Dolstra b581a56d79 * Define the Upstart package to use in one place.
svn path=/nixos/branches/upstart-0.6/; revision=18187
2009-11-06 09:36:35 +00:00
Eelco Dolstra 5fc4590ce5 * Fix indentation.
svn path=/nixos/branches/upstart-0.6/; revision=18186
2009-11-06 09:26:36 +00:00
Nicolas Pierron 8c5b200164 * boor.loader.grub.device can only be defined once.
* Replace an obscure piece of code by its equivalent based on the
  recursiveUpdate function.  Undefined the obsolete name of
  boot.grubDevice to avoid conflicts.

svn path=/nixos/trunk/; revision=18049
2009-10-30 11:57:23 +00:00
Eelco Dolstra 11022e8d9f * Back out r17946 and 17948 because it doesn't work. I've seen it
fail to update /etc twice now.  It's also unnecessarily complex
  IMHO (see nix-dev).

svn path=/nixos/trunk/; revision=18045
2009-10-30 08:37:08 +00:00
Michael Raskin ca6f5e6cd4 Further reducing writes on boot.. Do not copy /etc unless it changed
svn path=/nixos/trunk/; revision=17948
2009-10-24 00:03:13 +00:00
Michael Raskin 893f13bb14 Some boot optimisations attempted. My system boots a few times faster now, and I cannot see how these can break things.
svn path=/nixos/trunk/; revision=17946
2009-10-23 20:30:12 +00:00
Eelco Dolstra 5dfaf565bf * On the CD or on a newly installed system, create the root account
with an empty password, rather than with a hashed empty password.
  The latter is a security risk, because it allows remote root logins
  if a user enables sshd before setting a proper root password.
* Allow empty passwords for login and slim, but nothing else.

svn path=/nixos/trunk/; revision=17833
2009-10-15 14:41:59 +00:00
Ludovic Courtès f9541e0d12 Add GRUB 2 support.
svn path=/nixos/trunk/; revision=17792
2009-10-13 21:39:18 +00:00
Eelco Dolstra eba8f94069 * jobAttrs -> jobs.
svn path=/nixos/trunk/; revision=17769
2009-10-12 18:09:34 +00:00
Eelco Dolstra 40c9057a49 * Remove the obsolete "jobs" option.
svn path=/nixos/trunk/; revision=17765
2009-10-12 17:32:30 +00:00
Eelco Dolstra d982f23f20 * Convert the remaining jobs to jobAttrs style.
svn path=/nixos/trunk/; revision=17764
2009-10-12 17:27:57 +00:00
Eelco Dolstra 9943e0762e * Update some more modules.
svn path=/nixos/trunk/; revision=17763
2009-10-12 17:09:38 +00:00
Eelco Dolstra e91d882a94 * Converted modules that were still using the old (concrete syntax)
style of declaring Upstart jobs.  While at it, converted them to the
  current NixOS module style and improved some option descriptions.
  Hopefully I didn't break too much :-)

svn path=/nixos/trunk/; revision=17761
2009-10-12 16:36:19 +00:00
Michael Raskin 32229e0c05 Make NixOS harder to kill on boot by leaving stale locks for mtab
svn path=/nixos/trunk/; revision=17734
2009-10-09 16:09:56 +00:00
Nicolas Pierron 2969f36b15 Add the computation of upstart-packages inside the job sub-module by adding
the option named "upstartPkg".

Move the obsolete option "services.extraJobs" to the rename module.

svn path=/nixos/trunk/; revision=17672
2009-10-06 09:30:13 +00:00
Marc Weber d0c68bc9ab adding jobAttrs which is filled from jobs contents
Purpose: Allow overwriding of properties such as:
           config.jobAttrs.sshd.startOn = "never";

thanks to Nicolas Pierron for reviewing and
extending nixpkgs to make this possible

I'll convert most of the jobs ASAP so please don't care
about the depreceateion much right now

svn path=/nixos/trunk/; revision=17650
2009-10-05 18:31:27 +00:00
Eelco Dolstra 636a9e7e32 * Add rename clauses for the old Grub options.
* Renamed some of the new Grub options to more sensible names
  (e.g. extraGrubEntries to extraEntries, bootMount to bootDevice,
  etc.).

svn path=/nixos/trunk/; revision=17494
2009-09-29 09:50:38 +00:00
Lluís Batlle i Rossell 75f6cd20da Making modular my previous changes for armv5tel. I updated the way to use
grub. Its options are no more inside 'boot', but inside 'boot.loader.grub'.
I added a new bootloader configuration for nixos, generationsDir. It creates
/boot/default/{init,initrd,kernel,system} symlinks, and the same for the generations
in /boot/system-$gen/{init,initrd,kernel,system}.

I can program the u-boot loader to load /boot/default files always, and have
a minimal nixos boot loader installer functionality. Additionally, I can refer
to the other system generations easily, with a simple 'ls' in /boot.

svn path=/nixos/trunk/; revision=17460
2009-09-27 21:51:37 +00:00
Eelco Dolstra c5d45514a1 * Don't restart dbus, since that causes ConsoleKit to forget about
current sessions.

svn path=/nixos/trunk/; revision=17452
2009-09-26 21:00:47 +00:00
Eelco Dolstra 693e017bfe * HAL expects a /media directory for mounting removable media.
svn path=/nixos/trunk/; revision=17437
2009-09-26 10:27:47 +00:00
Eelco Dolstra 69998a8d61 * libgcc_s.so is in $gcc/lib64 on x86_64-linux.
svn path=/nixos/trunk/; revision=17417
2009-09-25 12:34:09 +00:00
Lluís Batlle i Rossell ff1a79ed88 Fixing the top-level expression not to boot only from uImage, but keep on
booting vmlinuz in non armv5tel.

svn path=/nixos/trunk/; revision=17393
2009-09-23 20:51:09 +00:00
Lluís Batlle i Rossell 8b9f510b08 Removing grub from the system expression for armv5tel-linux.
svn path=/nixos/trunk/; revision=17392
2009-09-23 20:51:00 +00:00
Lluís Batlle i Rossell eab68acb35 Conditioning on /sys/power, and adding double patchelf for armv5tel-linux
svn path=/nixos/trunk/; revision=17390
2009-09-23 20:50:48 +00:00
Michael Raskin 69cc6ce3ec Refactoring modules and cleaning up a comment
svn path=/nixos/trunk/; revision=17310
2009-09-20 18:15:52 +00:00
Michael Raskin b9079b8da9 Returning selinux=0: convenient with allmodconfig
svn path=/nixos/trunk/; revision=17179
2009-09-16 11:03:15 +00:00
Nicolas Pierron a07e90d6f3 Update the documentation:
* Change the module syntax of the example to follow Eelco's suggestions.

* Add a section "Building your own NixOS CD", which explain how to replace
configuration.nix by the configuration file of a live CD/DVD.

* Fix "Testing the installer" and "Testing the initrd" to fit the location
of derivations.

svn path=/nixos/trunk/; revision=17105
2009-09-13 22:13:19 +00:00
Eelco Dolstra cbe27af191 * Removed an unnecessary flag.
svn path=/nixos/trunk/; revision=16999
2009-09-09 21:22:25 +00:00
Eelco Dolstra 17d287afa5 * Bump the number of maximum open files for Nix builders.
Our VM builds were causing Samba to go over this limit.

svn path=/nixos/trunk/; revision=16960
2009-09-04 15:27:52 +00:00
Eelco Dolstra 685335df2f * system.build.system -> system.build.toplevel, since the former name
is just too weird.

svn path=/nixos/trunk/; revision=16954
2009-09-04 09:29:18 +00:00
Eelco Dolstra 2892aed712 * lib/eval-config.nix: combined "configuration" and "extraModules"
into one argument "modules".
* release.nix: fixed the manual job.
* ISO generation: break an infinite recursion.  Don't know why this
  suddenly happens.  Probably because of the nixpkgs.config change,
  but I don't see why.  Maybe the option evaluation is too strict.

svn path=/nixos/trunk/; revision=16878
2009-08-27 11:57:43 +00:00
Michael Raskin 769dc2f7e6 Write an explanation for a rule edit needed by LiveCD
svn path=/nixos/trunk/; revision=16774
2009-08-19 17:24:33 +00:00
Eelco Dolstra 11c603c3fb * Fix booting from CD. 60-persistent-storage.rules requires some
variables set by 60-cdrom_id.rules.

svn path=/nixos/trunk/; revision=16773
2009-08-19 16:48:28 +00:00
Eelco Dolstra 88c505c9e0 * make-etc.sh: fixed the duplicate entry check.
* Inlined make-etc.nix since it's a trivial function.

svn path=/nixos/trunk/; revision=16728
2009-08-16 13:14:33 +00:00
Eelco Dolstra 25dbf1594e * Updates for the new udev and util-linux-ng: fsck is now in
util-linux-ng instead of e2fsprogs, blkid is in util-linux-ng, and
  we need to manually create /dev/.udev prior to starting udevd for
  some reason.

svn path=/nixos/trunk/; revision=16691
2009-08-11 21:12:37 +00:00
Eelco Dolstra fd56f110da * Clean up some boot messages.
svn path=/nixos/trunk/; revision=16689
2009-08-11 21:09:25 +00:00
Eelco Dolstra bed6fd6a61 * `umount -f' causes lots of problems, so don't do it.
svn path=/nixos/trunk/; revision=16688
2009-08-11 21:08:05 +00:00
Eelco Dolstra 167ccdd537 * Move the firmware loader into a separate module.
* services.udev.addFirmware -> hardware.firmware.

svn path=/nixos/trunk/; revision=16657
2009-08-10 19:27:15 +00:00
Eelco Dolstra 0ab6be1c81 * Restarting dbus no longer seems to kill the X server.
svn path=/nixos/trunk/; revision=16650
2009-08-10 16:18:51 +00:00
Ludovic Courtès ac29ad197b stage-1-init: Remove timeout from `fail()'.
Timeouts upon failure can be harmful, e.g., after a file system failure
that needs manual intervention.

svn path=/nixos/trunk/; revision=16637
2009-08-10 09:20:05 +00:00
Eelco Dolstra 6802a75076 * nixos-rebuild: replaced some environment variables with options
(e.g. --install-grub instead of $NIXOS_INSTALL_GRUB).  Also support
  some nix-build options (e.g. --show-trace and -j).

svn path=/nixos/branches/modular-nixos/; revision=16560
2009-08-03 12:36:15 +00:00
Eelco Dolstra bc54061cba svn path=/nixos/branches/modular-nixos/; revision=16557 2009-08-03 12:17:23 +00:00
Michael Raskin 137ce0907c Some fixes in on-boot activation
svn path=/nixos/branches/modular-nixos/; revision=16525
2009-07-31 08:32:53 +00:00
Michael Raskin f05682c84d Give some progress indications during Stage2 boot
svn path=/nixos/branches/modular-nixos/; revision=16523
2009-07-31 04:56:52 +00:00
Michael Raskin 6aba79bed5 Update child configuration generation
svn path=/nixos/branches/modular-nixos/; revision=16514
2009-07-30 04:20:23 +00:00
Eelco Dolstra 6119c399d8 * Support tasks in the new Upstart formalism.
* Swap task: fixed removing disabled swap devices.
* Swap task: specified the type of swapDevices.

svn path=/nixos/branches/modular-nixos/; revision=16396
2009-07-16 14:51:49 +00:00
Eelco Dolstra 7cb4503ad6 * More Upstart refactoring.
svn path=/nixos/branches/modular-nixos/; revision=16394
2009-07-16 13:55:11 +00:00
Eelco Dolstra bb292fdf04 * Support post-stop actions.
svn path=/nixos/branches/modular-nixos/; revision=16393
2009-07-16 13:46:49 +00:00
Eelco Dolstra 889311f4ca * Refactored the sshd module.
svn path=/nixos/branches/modular-nixos/; revision=16377
2009-07-15 15:53:39 +00:00
Eelco Dolstra c45cf3a28e * In the jobs attribute, support a more high-level way of specifying
jobs, e.g. (from the nscd job)

    { name = "nscd";

      description = "Name Service Cache Daemon";

      startOn = "startup";
      stopOn = "shutdown";

      environment = { LD_LIBRARY_PATH = nssModulesPath; };
        
      preStart =
        ''
          mkdir -m 0755 -p /var/run/nscd
          mkdir -m 0755 -p /var/db/nscd
        '';

      exec = "${pkgs.glibc}/sbin/nscd -f ${./nscd.conf} -d 2> /dev/null";
    };

  The Upstart job is generated from this.  The main goal is to provide
  some abstraction from the Upstart syntax.  For instance, this should
  make it easier to upgrade to newer versions of Upstart, to switch to
  an entirely different process management system (e.g. initng or
  launchd), or to test a job independantly from Upstart.  (However the
  startOn and stopOn attributes are tied to Upstart's event model.)

svn path=/nixos/branches/modular-nixos/; revision=16376
2009-07-15 15:24:11 +00:00
Eelco Dolstra 0e3bef4195 * Declare the type of jobs.
svn path=/nixos/branches/modular-nixos/; revision=16375
2009-07-15 13:41:00 +00:00
Eelco Dolstra 1424399002 * Simplify.
svn path=/nixos/branches/modular-nixos/; revision=16373
2009-07-15 12:52:32 +00:00
Eelco Dolstra 96fe3ba1b7 * Inline make-job.nix.
svn path=/nixos/branches/modular-nixos/; revision=16372
2009-07-15 11:38:17 +00:00
Eelco Dolstra 9d1e31117f * Get rid of the "users" and "groups" fields in jobs.
svn path=/nixos/branches/modular-nixos/; revision=16371
2009-07-15 11:34:55 +00:00
Eelco Dolstra ca8e00cafa * Got rid of the extraPath field in jobs (use
environment.systemPackages instead).  Also renamed
  services.extraJobs to jobs.

svn path=/nixos/branches/modular-nixos/; revision=16370
2009-07-15 11:19:11 +00:00
Eelco Dolstra def0be732f * job.extraHttpdConfig: not used anywhere.
svn path=/nixos/branches/modular-nixos/; revision=16369
2009-07-15 09:14:24 +00:00
Eelco Dolstra 118418ba31 * Refactoring the Upstart module. Got rid of job.extraEtc, it's
redundant now (modules can just define environment.etc).

svn path=/nixos/branches/modular-nixos/; revision=16367
2009-07-15 09:06:36 +00:00
Eelco Dolstra 9704472d1c Some hacks to support clean shutdowns of VMs that mount the Nix store
ove QEMU (and other NixOS instances that use a remote filesystem like
NFS):

* Don't take down the network interfaces during shutdown.
* Don't try to unmount the Nix store.  Usually, this doesn't work
  because it's still in use, but on remote filesystems like CIFS the
  `-f' umount flag actually works.

svn path=/nixos/branches/modular-nixos/; revision=16036
2009-06-24 13:33:03 +00:00
Eelco Dolstra 0b39f614e9 * Don't wait for CIFS "devices" (//share/path) to appear since they
won't.  This speeds up booting from CIFS a lot.

svn path=/nixos/branches/modular-nixos/; revision=16023
2009-06-22 14:44:48 +00:00
Eelco Dolstra 0f6d7c8862 * Use insmod from module_init_tools in the initrd, since the latest
klibc no longer has it.

svn path=/nixos/branches/modular-nixos/; revision=16019
2009-06-22 14:10:11 +00:00
Eelco Dolstra da77a6437f * qemu-vm.nix: automatically create and initialise the disk image if
it doesn't already exist.  Also set up some ad hoc port forwarding
  from the host to the guest.

svn path=/nixos/branches/modular-nixos/; revision=16012
2009-06-19 15:19:56 +00:00
Eelco Dolstra 9460a30851 * Use the fileSystems option to mount the host filesystem. Also, it
seems that mount.cifs isn't actually needed (anymore?).

svn path=/nixos/branches/modular-nixos/; revision=16000
2009-06-18 16:47:00 +00:00
Eelco Dolstra e08e7aedbc * Option boot.initrd.postMountCommands to specify additional shell
commands for in stage 1 of the boot.

svn path=/nixos/branches/modular-nixos/; revision=15998
2009-06-18 16:03:18 +00:00
Eelco Dolstra 16937dd23d * Make fsck on journaling filesystems optional (enabled by default).
This is because fsck.ext3 takes several minutes to recover the
  journal, whereas the ext3 implementation in the kernel only takes a
  few seconds.  I'd love to know why this is the case...

svn path=/nixos/branches/modular-nixos/; revision=15965
2009-06-15 16:47:37 +00:00
Eelco Dolstra 048e03377f * Don't try to run fsck on ISO-9660/UDF filesystems.
svn path=/nixos/branches/modular-nixos/; revision=15963
2009-06-15 15:50:36 +00:00
Eelco Dolstra ff58b5dede * Booting was broken when using the "label" option.
svn path=/nixos/branches/modular-nixos/; revision=15957
2009-06-14 11:08:44 +00:00
Nicolas Pierron 4001b66c88 Move the option declaration of filesystems.*.neededForBoot to boot/stage-1.nix.
svn path=/nixos/branches/modular-nixos/; revision=15940
2009-06-11 16:04:03 +00:00
Eelco Dolstra 1cea6b09ef * Compress the Nix store on the CD using squashfs. This reduces the
size of the i686-linux ISO image from 463 MiB to 147 MiB.  Hopefully
  it also speeds up installation due to reduced seek time and larger
  block sizes, but I haven't tested that yet (on real hardware).

svn path=/nixos/branches/modular-nixos/; revision=15930
2009-06-10 16:29:48 +00:00
Eelco Dolstra 31c6852403 * The menu.lst fragment in the top-level system derivation doesn't
seem to be used anywhere.  Removed.

svn path=/nixos/branches/modular-nixos/; revision=15928
2009-06-10 16:05:25 +00:00
Eelco Dolstra e940f1fbd7 * Cleaned up the error messages in the stage 1 init script.
* Use the basename from coreutils rather than a bash hack.

svn path=/nixos/branches/modular-nixos/; revision=15927
2009-06-10 15:02:39 +00:00
Eelco Dolstra 0a0260514d * Renamed boot.localCommands to boot.postBootCommands since it wasn't
such a good name (local to what?).

svn path=/nixos/branches/modular-nixos/; revision=15879
2009-06-05 16:02:58 +00:00
Eelco Dolstra f9cfe7c4ee * The activation script can't use /bin/sh as its interpreter because
it creates the /bin/sh symlink, which may not exist yet (esp. when
  booting from CD).

svn path=/nixos/branches/modular-nixos/; revision=15875
2009-06-05 15:03:56 +00:00
Eelco Dolstra d6617f0d5e svn path=/nixos/branches/modular-nixos/; revision=15866 2009-06-05 13:24:23 +00:00
Eelco Dolstra 234c4340c2 * helpers -> lib.
svn path=/nixos/branches/modular-nixos/; revision=15797
2009-05-29 14:46:27 +00:00
Eelco Dolstra c6c9304b95 * system/options.nix: gone :-)
svn path=/nixos/branches/modular-nixos/; revision=15772
2009-05-28 16:03:48 +00:00
Eelco Dolstra 29611e49fd * More cleanup.
svn path=/nixos/branches/modular-nixos/; revision=15768
2009-05-28 13:36:38 +00:00
Eelco Dolstra 3c84d56273 * Move the /etc generation to modules/system/etc.
svn path=/nixos/branches/modular-nixos/; revision=15767
2009-05-28 13:17:56 +00:00
Eelco Dolstra ec55562ec3 * Move the configuration of the pwdutils (passwd, useradd etc.) to
modules/programs/pwdutils.
* Renamed config.system.shell to config.users.defaultUserShell and
  updated the description to make clear it has to be a non-store
  path.

svn path=/nixos/branches/modular-nixos/; revision=15761
2009-05-28 12:24:56 +00:00
Eelco Dolstra 05a08adf91 * Move the dhclient exit hooks file to the dhclient module, where it
belongs.

svn path=/nixos/branches/modular-nixos/; revision=15755
2009-05-27 23:30:29 +00:00
Eelco Dolstra 3c6ae39a0d * Refactoring: moved some options out of system/options.nix (almost
empty now), do more of bashrc.sh declaratively, and moved nsswitch
  generation to modules/config/nsswitch.nix.

svn path=/nixos/branches/modular-nixos/; revision=15754
2009-05-27 23:14:38 +00:00
Eelco Dolstra c3fb0387b4 * Moved the expressions for generating Upstart jobs.
svn path=/nixos/branches/modular-nixos/; revision=15748
2009-05-27 10:32:30 +00:00
Eelco Dolstra 700a1f8f21 * Move the modulesTree and modprobe options to the kernel.nix module.
svn path=/nixos/branches/modular-nixos/; revision=15747
2009-05-27 09:57:30 +00:00
Eelco Dolstra 690416cf1a * Move initrd-related options to the appropriate module.
svn path=/nixos/branches/modular-nixos/; revision=15746
2009-05-27 09:46:50 +00:00
Eelco Dolstra 68c3132f46 * Move the activation scripts to the appropriate module.
svn path=/nixos/branches/modular-nixos/; revision=15745
2009-05-27 09:40:55 +00:00
Eelco Dolstra 98cce35041 * Turn the top-level derivation of a NixOS configuration ("system")
into a NixOS module (modules/system/activation/top-level.nix -
  couldn't think of a better name).  The top-level derivation is
  returned in config.system.build.system.
* Inlined system.sh in top-level.nix so that we don't have to pass
  everything through environment variables.

svn path=/nixos/branches/modular-nixos/; revision=15740
2009-05-27 09:00:45 +00:00
Eelco Dolstra 7ac0b3aaea * Make modules/system/boot/stage-1.nix a proper module that exports
the initial ramdisk as config.system.build.bootStage1.

svn path=/nixos/branches/modular-nixos/; revision=15739
2009-05-27 08:14:06 +00:00
Eelco Dolstra 278b15d840 * More moving.
svn path=/nixos/branches/modular-nixos/; revision=15725
2009-05-25 14:19:33 +00:00