diff --git a/hosts/archangel/configuration.nix b/hosts/archangel/configuration.nix index b6e6160..d2794ab 100644 --- a/hosts/archangel/configuration.nix +++ b/hosts/archangel/configuration.nix @@ -37,14 +37,13 @@ ]; }; - networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. + networking.networkmanager.enable = true; # Enables wireless support via wpa_supplicant. # Configure network proxy if necessary # networking.proxy.default = "http://user:password@proxy:port/"; # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain"; # Enable networking - networking.networkmanager.enable = true; # Set your time zone. time.timeZone = "Europe/Istanbul"; @@ -59,7 +58,7 @@ users.users.tulg = { isNormalUser = true; description = "Tulga"; - extraGroups = [ "networkmanager" "wheel" ]; + extraGroups = [ "networkmanager" "network ""wheel" ]; packages = with pkgs; []; }; @@ -117,6 +116,22 @@ }; }; + + powerManagement.powertop.enable = true; + services = { + power-profiles-daemon.enable = false; + tlp = { + enable = true; + settings = { + CPU_BOOST_ON_AC = 1; + CPU_BOOST_ON_BAT = 0; + CPU_SCALING_GOVERNOR_ON_AC = "performance"; + CPU_SCALING_GOVERNOR_ON_BAT = "powersave"; + STOP_CHARGE_THRESH_BAT0 = 95; + }; + }; + }; + # Open ports in the firewall. # networking.firewall.allowedTCPPorts = [ ... ]; # networking.firewall.allowedUDPPorts = [ ... ]; diff --git a/hosts/archangel/hardware-configuration.nix b/hosts/archangel/hardware-configuration.nix new file mode 100644 index 0000000..80e97df --- /dev/null +++ b/hosts/archangel/hardware-configuration.nix @@ -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 = [ "nvme" "xhci_pci" "usb_storage" "sd_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ "kvm-amd" ]; + boot.extraModulePackages = [ ]; + + fileSystems."/" = + { device = "/dev/disk/by-uuid/48340a1a-5055-4d72-b83b-db57a3a7e230"; + fsType = "ext4"; + }; + + fileSystems."/boot" = + { device = "/dev/disk/by-uuid/5292-3A27"; + fsType = "vfat"; + options = [ "fmask=0022" "dmask=0022" ]; + }; + + 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..useDHCP`. + networking.useDHCP = lib.mkDefault true; + # networking.interfaces.enp1s0.useDHCP = lib.mkDefault true; + # networking.interfaces.wlp2s0.useDHCP = lib.mkDefault true; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; +}