141 lines
3.3 KiB
Nix
141 lines
3.3 KiB
Nix
{ config, pkgs, lib, self, ... }:
|
|
|
|
{
|
|
system.stateVersion = "23.05";
|
|
# Hardware
|
|
hardware = {
|
|
enableRedistributableFirmware = lib.mkDefault true;
|
|
cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
pulseaudio.enable = false;
|
|
bluetooth = {
|
|
enable = true; # enables support for Bluetooth
|
|
powerOnBoot = true; # powers up the default Bluetooth controller on boot
|
|
settings = {
|
|
General = {
|
|
Enable = "Source,Sink,Media,Socket";
|
|
};
|
|
};
|
|
};
|
|
};
|
|
|
|
# Boot
|
|
boot = {
|
|
loader = {
|
|
systemd-boot.enable = true;
|
|
efi.canTouchEfiVariables = true;
|
|
};
|
|
initrd = {
|
|
availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usb_storage" "sd_mod" ];
|
|
kernelModules = [ ];
|
|
};
|
|
kernelModules = [ "kvm-intel" ];
|
|
extraModulePackages = [ ];
|
|
# Prevent tampering of the pkgstore
|
|
readOnlyNixStore = true;
|
|
};
|
|
|
|
fileSystems = {
|
|
"/" = {
|
|
device = "/dev/disk/by-uuid/55c746b3-b9dc-4c9b-ab56-de68a561f9a3";
|
|
fsType = "ext4";
|
|
};
|
|
"/boot" = {
|
|
device = "/dev/disk/by-uuid/0C59-9996";
|
|
fsType = "vfat";
|
|
};
|
|
};
|
|
|
|
swapDevices = [ ];
|
|
|
|
# Networking
|
|
networking = {
|
|
hostName = "katana"; # Define your hostname.
|
|
networkmanager.enable = true; #Enable Network Manager
|
|
firewall = {
|
|
checkReversePath = "loose";
|
|
allowedTCPPorts = [ ];
|
|
allowedUDPPorts = [ ];
|
|
};
|
|
};
|
|
|
|
# Sound
|
|
sound.enable = true;
|
|
|
|
# Localization
|
|
time.timeZone = "America/Detroit";
|
|
i18n = {
|
|
defaultLocale = "en_US.UTF-8";
|
|
extraLocaleSettings = {
|
|
LC_ADDRESS = "en_US.UTF-8";
|
|
LC_IDENTIFICATION = "en_US.UTF-8";
|
|
LC_MEASUREMENT = "en_US.UTF-8";
|
|
LC_MONETARY = "en_US.UTF-8";
|
|
LC_NAME = "en_US.UTF-8";
|
|
LC_NUMERIC = "en_US.UTF-8";
|
|
LC_PAPER = "en_US.UTF-8";
|
|
LC_TELEPHONE = "en_US.UTF-8";
|
|
LC_TIME = "en_US.UTF-8";
|
|
};
|
|
};
|
|
|
|
# Services.
|
|
services = {
|
|
blueman.enable = true;
|
|
printing.enable = true;
|
|
xserver = {
|
|
layout = "us";
|
|
xkbVariant = "";
|
|
};
|
|
};
|
|
|
|
# Package Manager
|
|
nixpkgs = {
|
|
config.allowUnfree = true;
|
|
hostPlatform = lib.mkDefault "x86_64-linux";
|
|
};
|
|
|
|
nix = {
|
|
# Sets flakes to unstable track instead of stable #
|
|
package = pkgs.nixUnstable; # or versioned attributes like nix_2_4
|
|
# Enable flakes and nix-command
|
|
extraOptions = ''experimental-features = nix-command flakes'';
|
|
# Auto maintainence
|
|
settings.auto-optimise-store = lib.mkDefault true;
|
|
# Garbage collection
|
|
gc = {
|
|
automatic = true;
|
|
dates = "weekly";
|
|
options = "--delete-older-than 7d";
|
|
};
|
|
};
|
|
|
|
environment.systemPackages = with pkgs; [
|
|
gparted
|
|
bluez
|
|
blueman
|
|
nerdfonts
|
|
home-manager
|
|
pkg-config
|
|
ripgrep
|
|
openssl
|
|
tree
|
|
eza
|
|
htop
|
|
zsh
|
|
dig #dns lookup
|
|
rage #file encryption
|
|
age-plugin-yubikey #plugin for rage to manage yubi-2fa
|
|
sops #file based secrets operations
|
|
direnv #used for development environments
|
|
gcc
|
|
bottom
|
|
felix-fm
|
|
zulip
|
|
vscode
|
|
];
|
|
|
|
# Fonts
|
|
fonts.packages = with pkgs; [
|
|
(nerdfonts.override { fonts = [ "SourceCodePro" "DroidSansMono" ]; })
|
|
];
|
|
}
|