Commit graph

51 commits

Author SHA1 Message Date
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 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 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 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 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
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
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 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
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
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
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 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 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 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 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 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
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 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 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
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
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 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
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 6aba79bed5 Update child configuration generation
svn path=/nixos/branches/modular-nixos/; revision=16514
2009-07-30 04:20:23 +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 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 29611e49fd * More cleanup.
svn path=/nixos/branches/modular-nixos/; revision=15768
2009-05-28 13:36:38 +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 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