Created
August 7, 2019 23:31
-
-
Save exarkun/d54f5e8cacbb1cdf995393ce1d31cf47 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ config, pkgs, lib, ... }: | |
let | |
cleverca22-nixos-configs = pkgs.fetchFromGitHub | |
{ owner = "cleverca22"; | |
repo = "nixos-configs"; | |
rev = "bd0d30c6ac0c0d40f295fda9675338b832dd317b"; | |
sha256 = "1y1jpfcjwyla0vziih6xqhd98imyc3glmxzyg36xkh5hjpnmi6l6"; | |
}; | |
in | |
{ | |
imports = [ | |
# Get a module for using qemu-user-{arm,aarch64} via binfmt misc to run | |
# arm binaries. This is useful for cross-compiling to arm. | |
"${cleverca22-nixos-configs}/qemu.nix" | |
]; | |
# Via the cleverca22/nixos-configs module, enable qemu execution of arm and | |
# aarch64 via binfmt misc. | |
qemu-user = { | |
arm = true; | |
aarch64 = true; | |
}; | |
nix.distributedBuilds = true; | |
# Use the systemd-boot EFI boot loader. | |
boot.loader.systemd-boot.enable = true; | |
boot.loader.efi.canTouchEfiVariables = true; | |
boot.extraModulePackages = with config.boot.kernelPackages; [ | |
# Support tlp. Without this: | |
# "Error: ThinkPad battery features not available." | |
acpi_call | |
]; | |
# This value determines the NixOS release with which your system is to be | |
# compatible, in order to avoid breaking some software such as database | |
# servers. You should change this only after NixOS release notes say you | |
# should. | |
system.stateVersion = "19.03"; # Did you read the comment? | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment