Skip to content

Instantly share code, notes, and snippets.

@shlevy
Created March 6, 2011 14:02
Show Gist options
  • Save shlevy/857307 to your computer and use it in GitHub Desktop.
Save shlevy/857307 to your computer and use it in GitHub Desktop.
# Edit this configuration file which defines what would be installed on the
# system. To Help while choosing option value, you can watch at the manual
# page of configuration.nix or at the last chapter of the manual available
# on the virtual console 8 (Alt+F8).
{config, pkgs, ...}:
{
require = [
# Include the configuration for part of your system which have been
# detected automatically. In addition, it includes the same
# configuration as the installation device that you used.
./hardware-configuration.nix
];
boot.initrd.availableKernelModules = [
"ext4"
];
# boot.kernelPackages = pkgs.linuxPackages_2_6_37;
boot.loader.grub = {
# Use grub 2 as boot loader.
enable = true;
version = 2;
# Define on which hard drive you want to install Grub.
device = "nodev";
};
networking = {
hostName = "nixos";
interfaceMonitor.enable = true; # Watch for plugged cable.
enableWLAN = false;
};
# Add file system entries for each partition that you want to see mounted
# at boot time. You can add filesystems which are not mounted at boot by
# adding the noauto option.
fileSystems = [
{ mountPoint = "/";
device = "/dev/sdb3";
label = "NixOS /";
fsType = "ext4";
}
{ mountPoint = "/boot/efi";
device = "/dev/sdb1";
label = "EFI System";
fsType = "vfat";
}
];
swapDevices = [
{ device = "/dev/sdb2"; }
];
# Select internationalisation properties.
# i18n = {
# consoleFont = "lat9w-16";
# consoleKeyMap = "us";
# defaultLocale = "en_US.UTF-8";
# };
# List services that you want to enable:
# Add an OpenSSH daemon.
# services.openssh.enable = true;
# Add CUPS to print documents.
# services.printing.enable = true;
# Add XServer (default if you have used a graphical iso)
# services.xserver = {
# enable = true;
# layout = "us";
# xkbOptions = "eurosign:e";
# };
# Add the NixOS Manual on virtual console 8
services.nixosManual.showManual = true;
}
# This is a generated file. Do not modify!
# Make changes to /etc/nixos/configuration.nix instead.
{ config, pkgs, modulesPath, ... }:
{
require = [
"${modulesPath}/profiles/base.nix"
"${modulesPath}/installer/scan/not-detected.nix"
];
boot.initrd.kernelModules = [ "ehci_hcd" "ahci" "xhci" "ohci1394" ];
boot.kernelModules = [ "acpi-cpufreq" "kvm-intel" ];
boot.extraModulePackages = [ ];
nix.maxJobs = 8;
services.xserver.videoDriver = "vesa";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment