Add laptop host

pull/1/head
Carsten Kragelund 2023-01-16 14:49:16 +01:00
parent b6b8bea3a4
commit 8579155fab
Signed by: nyx
GPG Key ID: CADDADEEC9F753C0
4 changed files with 202 additions and 0 deletions

@ -16,6 +16,19 @@
modules = [
./hosts/falcon
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.backupFileExtension = "bak";
}
];
};
nixosConfigurations.eagle = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
./hosts/eagle
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;

@ -0,0 +1,125 @@
{ config
, modulesPath
, pkgs
, ...
}: {
imports = [
./hardware.nix
../../users/carsten
../common.nix
./pkgs.nix
];
# Enable non-free packages
nixpkgs.config.allowUnfree = true;
boot.loader = {
systemd-boot = {
enable = true;
};
efi = {
canTouchEfiVariables = true;
efiSysMountPoint = "/boot/efi";
};
};
# Configure nix itself
nix = {
# Enable nix flakes
package = pkgs.nixFlakes;
settings = {
# Maximum number of concurrent tasks during one build
build-cores = 12;
# Maximum number of jobs that Nix will try to build in parallel
max-jobs = "auto";
# Perform builds in a sandboxed environment
sandbox = true;
# Enable flakes
experimental-features = [ "nix-command" "flakes" ];
};
};
# Set your time zone.
time.timeZone = "Europe/Copenhagen";
# Select internationalisation properties.
i18n.defaultLocale = "en_US.utf8";
i18n.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";
};
# Configure console keymap
console.keyMap = "us";
# Audio
sound.enable = true;
hardware.pulseaudio.enable = false;
security.rtkit.enable = true;
services.pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
};
# Pinentry / GPG
programs.gnupg.agent = {
enable = true;
pinentryFlavor = "gtk2";
enableSSHSupport = true;
};
security.pam.loginLimits = [
# Unlimited amount of processes for root
{
domain = "root";
item = "nproc";
value = "unlimited";
}
# Unlimited open file descriptors
{
domain = "*";
item = "nofile";
value = "unlimited";
}
];
networking = {
networkmanager.enable = true;
hostName = "eagle";
nameservers = [ "192.168.1.1" "87.62.97.64" ];
};
services.xserver = {
enable = true;
layout = "us";
xkbVariant = "";
displayManager.gdm.enable = true;
desktopManager.gnome.enable = true;
};
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "22.11"; # Did you read the comment?
}

@ -0,0 +1,39 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/46f02208-9100-454f-8946-8a02190fcd9c";
fsType = "ext4";
};
fileSystems."/boot/efi" =
{ device = "/dev/disk/by-uuid/541D-6B1B";
fsType = "vfat";
};
swapDevices = [ ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.eno2.useDHCP = lib.mkDefault true;
# networking.interfaces.wlo1.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

@ -0,0 +1,25 @@
{ pkgs, ... }:
{
imports = [ ];
environment.systemPackages = with pkgs; [
(firefox-devedition-bin.override { wmClass = "firefox-aurora"; })
dconf
git
git-lfs
gnomeExtensions.color-picker
gnomeExtensions.just-perfection
gnomeExtensions.unite
gnupg
home-manager
ntfsprogs
pinentry-gtk2
pipewire
pulseaudio
unzip
vim
wget
wireplumber
];
}