-
-
Save boomshroom/f17bd0184d9425208b72de13c1cfa18a 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
# Edit this configuration file to define what should be installed on | |
# your system. Help is available in the configuration.nix(5) man page | |
# and in the NixOS manual (accessible by running ‘nixos-help’). | |
{ config, pkgs, ... }: | |
{ | |
imports = | |
[ # Include the results of the hardware scan. | |
./hardware-configuration.nix | |
# Platform specific, non-critical, configuration. | |
./platform-configuration.nix | |
(let cleverRepo = pkgs.fetchFromGitHub { | |
owner = "cleverca22"; | |
repo = "nixos-configs"; | |
rev = "11b06fa78dc34a94a335ee221af424a5f6a3b2ca"; | |
sha256 = "0000000000000000000000000000000000000000000000000000"; | |
}; in builtins.toPath "${cleverRepo}/qemu.nix") | |
]; | |
# Use the systemd-boot EFI boot loader. | |
boot.loader.systemd-boot.enable = true; | |
boot.loader.efi.canTouchEfiVariables = true; | |
boot.binfmtMiscRegistrations = { | |
golang = { | |
recognitionType = "extension"; | |
magicOrExtension = "go"; | |
interpreter = pkgs.runCommand "go-run" { buildInputs = [pkgs.makeWrapper]; } "makeWrapper ${pkgs.go}/bin/go $out --add-flags run"; | |
}; | |
javaJar = { | |
recognitionType = "extension"; | |
magicOrExtension = "jar"; | |
interpreter = pkgs.runCommand "java-jar" { buildInputs = [pkgs.makeWrapper]; } "makeWrapper ${pkgs.jre}/bin/java $out --add-flags -jar"; | |
}; | |
javaClass = { | |
recognitionType = "magic"; | |
magicOrExtension = "\xCA\xFE\xBA\xBE"; | |
interpreter = "${pkgs.jre}/bin/java"; | |
}; | |
wine = { | |
magicOrExtension = "MZ"; | |
interpreter = "${pkgs.wine}/bin/wine"; | |
}; | |
}; | |
qemu-user.arm.enable = true; | |
qemu-user.aarch64.enable = true; | |
#networking.hostName = "angelo-nixos"; # Define your hostname. | |
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. | |
# Select internationalisation properties. | |
i18n = { | |
consoleFont = "Lat2-Terminus16"; | |
consoleKeyMap = "us"; | |
#consoleKeyMap = "colmak" | |
defaultLocale = "en_CA.UTF-8"; | |
}; | |
# Set your time zone. | |
# time.timeZone = "Europe/Amsterdam"; | |
# List packages installed in system profile. To search by name, run: | |
# $ nix-env -qaP | grep wget | |
# environment.systemPackages = with pkgs; [ | |
# wget | |
# ]; | |
time.timeZone = "Canada/Pacific"; | |
programs.fish = { | |
enable = true; | |
vendor.completions.enable = true; | |
shellAliases = { clean-store = "nix-store --gc; nix-store --optimise"; }; | |
}; | |
fonts = { | |
enableDefaultFonts = true; | |
fonts = [ pkgs.symbola ]; | |
}; | |
nix = { | |
trustedUsers = [ "root" "angelo" "builder" ]; | |
#allowedUsers = [ "builder" ]; | |
optimise.automatic = true; | |
#sshServe.enable = true; | |
maxJobs = 8; | |
extraOptions = "secret-key-files = /etc/nix/signing.sec"; | |
supportedPlforms = ["i686-cygwin" "x86_64-cygwin"]; | |
}; | |
programs.command-not-found.enable = true; | |
programs.adb.enable = true; | |
virtualisation.virtualbox.host.enable = true; | |
# environment.systemPackages = [(pkgs.steam.override { newStdcpp = true; })]; | |
nixpkgs.config.allowUnfree = true; | |
# List services that you want to enable: | |
services.udev.extraRules = '' | |
SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ATTRS{idVendor}=="057e", ATTRS{idProduct}=="0337", MODE="0666", TAG+="uaccess" | |
SUBSYSTEM=="usb", ATTRS{idVendor}=="28de", MODE="0666", TAG+="uaccess" | |
KERNEL=="uinput", SUBSYSTEM=="misc", OPTIONS+="static_node=uinput", TAG+="uaccess" | |
''; | |
# Open ports in the firewall. | |
# networking.firewall.allowedTCPPorts = [ ... ]; | |
# networking.firewall.allowedUDPPorts = [ ... ]; | |
# Or disable the firewall altogether. | |
# networking.firewall.enable = false; | |
services.apcupsd.enable = true; | |
# Enable CUPS to print documents. | |
services.printing.enable = true; | |
# Enable the X11 windowing system. | |
services.xserver.enable = true; | |
#services.xserver.layout = "us"; | |
#services.xserver.xkbVariant = "colemak"; | |
# services.xserver.xkbOptions = "eurosign:e"; | |
services.xserver.windowManager.i3.enable = true; | |
# Enable the KDE Desktop Environment. | |
services.xserver.displayManager = { | |
lightdm.enable = true; | |
sddm = { | |
enable = pkgs.stdenv.lib.mkForce false; | |
# autoNumlock = true; | |
}; | |
}; | |
hardware.opengl.driSupport32Bit = true; | |
# services.xserver.desktopManager.plasma5.enable = true; | |
# Define a user account. Don't forget to set a password with ‘passwd’. | |
users.users.angelo = { | |
isNormalUser = true; | |
#home = "/home/angelo-nixos"; | |
extraGroups = [ "wheel" "networkmanager" "adbusers" ]; | |
shell = pkgs.fish; | |
#openssh.authorizedKeys.keys = | |
#[ ] | |
}; | |
users.users.builder = { | |
isSystemUser = true; | |
useDefaultShell = true; | |
openssh.authorizedKeys.keys = [ | |
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC/w3AKXXtxp25/9dA6ResSyVRjK6+419FMZu9W2P0t58+QZ/rkkv0txE//n9/+IbqHWA0u0qsAfkSWDZMMMT7BZnxlnnOalx/Xeebp17MryA1bu6AMWzzJuq3cOfETrml5JJoHlCTUXQz9Q3AMLyR1QXhIYOtUOeS3V7HOTdfiYLtf0rMOVsoR49RFDU0QCIvE4xF5Gt1YbU7tA5n3cRuU65k+rFge3suYfOyEmSSp7PsP4R9TX2jtegx3zGKdPFQeQz/FK6+RTrEqeGzs1UDOk+xcf1lNq8kK9skw7q19Z5owqfpodMelfO2PshuqMrVLZQUDkuWGzRTlnurfOB7D root@angelo-macbook" | |
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDAwNW1kMfLwX3KLpVtuMGAbHRFa/Kt0Oaqa75uMuYh19Wsku8/kc43d60/fTdoGeyqiMWa1fmv4ujIuTCTuBz7yZrvjvtqzbcIl5yqacmazdBoYWHgqixUexC+ASBOVSdqTx3ssnn9vDw6+eYpZ4sVEs+7B5dFjL4rWEQX6g0FkNBtvItJSyru9MM2icx1fG/WSvSktg03eWtnqagJbDjmdPbOZ7WOYyL5DXswPZzuzIMyUggpR3zYFG4fgnaWFhoWusrjmnRsZ14Bi4X+ELocNz34DpbHBkZKGjTmnTyln4QFSjnjThneOF6S19/vFKEDveNHo3gHDlf8nbEBdrWH abulfone@linux2" | |
]; | |
}; | |
# The NixOS release to be compatible with for stateful data such as databases. | |
system.stateVersion = "17.03"; | |
system.autoUpgrade.enable = true; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment