* Use the configuration in /etc/nixos/configuration.nix by default.

svn path=/nixos/trunk/; revision=7319
This commit is contained in:
Eelco Dolstra 2006-12-12 00:08:26 +00:00
parent 2d0f190f20
commit 482a6625a9
3 changed files with 12 additions and 6 deletions

View file

@ -41,6 +41,8 @@ test -e /etc/fstab || touch /etc/fstab # idem
mount -n -t proc none /proc mount -n -t proc none /proc
cat /proc/mounts > /etc/mtab cat /proc/mounts > /etc/mtab
mkdir -m 0755 -p /etc/nixos
# Process the kernel command line. # Process the kernel command line.
for o in $(cat /proc/cmdline); do for o in $(cat /proc/cmdline); do

View file

@ -1,6 +1,8 @@
#! /bin/sh #! /bin/sh -e
set -e if test -z "$NIXOS_CONFIG"; then
NIXOS_CONFIG=/etc/nixos/configuration.nix
fi
nix-build configuration/system.nix \ nix-build configuration/system.nix \
--arg configuration 'import ./instances/example.nix' \ --arg configuration "import $NIXOS_CONFIG" \
-A system -K -k -A system -K -k
./result/bin/switch-to-configuration test ./result/bin/switch-to-configuration test

View file

@ -1,6 +1,8 @@
#! /bin/sh #! /bin/sh -e
set -e if test -z "$NIXOS_CONFIG"; then
NIXOS_CONFIG=/etc/nixos/configuration.nix
fi
nix-env -p /nix/var/nix/profiles/system -f configuration/system.nix \ nix-env -p /nix/var/nix/profiles/system -f configuration/system.nix \
--arg configuration 'import ./instances/example.nix' \ --arg configuration "import $NIXOS_CONFIG" \
-i -A system -i -A system
/nix/var/nix/profiles/system/bin/switch-to-configuration switch /nix/var/nix/profiles/system/bin/switch-to-configuration switch