* Move the configuration examples to doc/.

svn path=/nixos/trunk/; revision=12723
This commit is contained in:
Eelco Dolstra
2008-08-26 13:01:16 +00:00
parent 3116621c46
commit 8c2fd764e2
6 changed files with 2 additions and 2 deletions

View File

@@ -0,0 +1,21 @@
{
boot = {
grubDevice = "/dev/sda";
};
fileSystems = [
{ mountPoint = "/";
device = "/dev/sda1";
}
];
swapDevices = [
{ device = "/dev/sdb1"; }
];
services = {
sshd = {
enable = true;
};
};
}

View File

@@ -0,0 +1,32 @@
{
boot = {
grubDevice = "/dev/sda";
copyKernels = true;
bootMount = "(hd0,0)";
};
fileSystems = [
{ mountPoint = "/";
device = "/dev/sda3";
}
{ mountPoint = "/boot";
device = "/dev/sda1";
neededForBoot = true;
}
];
swapDevices = [
{ device = "/dev/sda2"; }
];
services = {
sshd = {
enable = true;
};
};
fonts = {
enableFontConfig = false;
};
}

View File

@@ -0,0 +1,36 @@
# This configuration has / on a LVM volume. Since Grub
# doesn't know about LVM, a separate /boot is therefore
# needed. In particular you need to set "copyKernels"
# to tell NixOS to copy kernels and initrds from /nix/store
# to /boot, and "bootMount" to tell Grub the /boot device
# in Grub syntax (e.g. (hd0,0) for /dev/sda1).
#
# In this example, labels are used for file systems and
# swap devices: "boot" might be /dev/sda1, "root" might be
# /dev/my-volume-group/root, and "swap" might be /dev/sda2.
# In particular there is no specific reference to the fact
# that / is on LVM; that's figured out automatically.
{
boot = {
grubDevice = "/dev/sda";
initrd = {
extraKernelModules = ["ata_piix"];
};
copyKernels = true;
bootMount = "(hd0,0)";
};
fileSystems = [
{ mountPoint = "/";
label = "root";
}
{ mountPoint = "/boot";
label = "boot";
}
];
swapDevices = [
{ label = "swap"; }
];
}

View File

@@ -0,0 +1,36 @@
{
boot = {
grubDevice = "/dev/sda";
};
fileSystems = [
{ mountPoint = "/";
device = "/dev/sda1";
}
];
services = {
sshd = {
enable = true;
};
httpd = {
enable = true;
adminAddr = "admin@example.org";
subservices = {
subversion = {
enable = true;
dataDir = "/data/subversion";
notificationSender = "svn@example.org";
};
};
};
};
}

View File

@@ -0,0 +1,27 @@
# Configuration file used to install NixOS-x86_64 on a USB stick.
{
boot = {
grubDevice = "/dev/sda";
initrd = {
extraKernelModules = ["usb_storage" "ehci_hcd" "ohci_hcd"];
enableSplashScreen = false;
};
};
fileSystems = [
{ mountPoint = "/";
label = "nixos-usb";
}
];
services = {
ttyBackgrounds = {
enable = false;
};
};
fonts = {
enableFontConfig = false;
};
}

View File

@@ -147,10 +147,10 @@ $ lvcreate --size 1G --name smalldisk MyVolGroup</screen>
activated. The configuration is specified in a Nix expression and
must be stored <emphasis>on the target file system</emphasis> in
<filename>/mnt/etc/nixos/configuration.nix</filename>. See
<filename>/etc/nixos/nixos/configuration/examples</filename> for
<filename>/etc/nixos/nixos/doc/config-examples</filename> for
example machine configurations. You can copy and edit one of
those (e.g., copy
<filename>/etc/nixos/nixos/configuration/examples/basic.nix</filename>
<filename>/etc/nixos/nixos/doc/config-examples/basic.nix</filename>
to <filename>/mnt/etc/nixos/configuration.nix</filename>). See
<xref linkend="ch-options"/> for a list of the available
configuration options. The text editors <command>nano</command>