78 lines
		
	
	
		
			2.0 KiB
		
	
	
	
		
			Nix
		
	
	
	
	
	
			
		
		
	
	
			78 lines
		
	
	
		
			2.0 KiB
		
	
	
	
		
			Nix
		
	
	
	
	
	
# 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 = [
 | 
						||
    ../../modules/system.nix
 | 
						||
    ../../modules/nix-settings.nix
 | 
						||
    ../../modules/vpn.nix
 | 
						||
    ../../modules/fonts.nix
 | 
						||
    ../../modules/firewall.nix
 | 
						||
    ../../modules/localisation.nix
 | 
						||
    ../../modules/openssh.nix
 | 
						||
    ../../modules/pipewire.nix
 | 
						||
    ../../modules/services.nix
 | 
						||
    ../../modules/regreet/regreet.nix
 | 
						||
    ../../modules/plymouth.nix
 | 
						||
    # Include the results of the hardware scan.
 | 
						||
    ./hardware-configuration.nix
 | 
						||
  ];
 | 
						||
 | 
						||
  # Brightness Control
 | 
						||
  # Enabled and Kernel patched to control screen Brightness on Notebook
 | 
						||
  environment.systemPackages = with pkgs; [ brightnessctl ];
 | 
						||
  services.udev.extraRules = ''
 | 
						||
    		ACTION=="add", SUBSYSTEM=="backlight", KERNEL=="*", RUN+="${pkgs.coreutils}/bin/chmod a+w /sys/class/backlight/%k/brightness"
 | 
						||
    	'';
 | 
						||
 | 
						||
  boot.loader = {
 | 
						||
    systemd-boot.enable = true;
 | 
						||
    efi.canTouchEfiVariables = true;
 | 
						||
  };
 | 
						||
 | 
						||
  networking = {
 | 
						||
    hostName = "nix-hp";
 | 
						||
    #networkmanager.enable = true;
 | 
						||
 | 
						||
    wireless = {
 | 
						||
      enable = true;
 | 
						||
      networks = {
 | 
						||
        LANFRED.pskRaw = "36e2b41b51328800a9582be1a05f13f796f943569610ccdb61304803b86ce3da";
 | 
						||
      };
 | 
						||
    };
 | 
						||
 | 
						||
    nameservers = [
 | 
						||
      "1.1.1.1"
 | 
						||
      "1.0.0.1"
 | 
						||
      "8.8.8.8"
 | 
						||
      "8.8.4.4"
 | 
						||
    ];
 | 
						||
  };
 | 
						||
 | 
						||
  nixpkgs.config.nvidia.acceptLicense = true;
 | 
						||
  hardware.graphics.enable = true;
 | 
						||
  services.xserver.videoDrivers = [ "nvidia" ];
 | 
						||
  hardware.nvidia = {
 | 
						||
    package = config.boot.kernelPackages.nvidiaPackages.legacy_470;
 | 
						||
    modesetting.enable = true;
 | 
						||
    open = false;
 | 
						||
    powerManagement = {
 | 
						||
      enable = false;
 | 
						||
      finegrained = false;
 | 
						||
    };
 | 
						||
    nvidiaSettings = true;
 | 
						||
 | 
						||
    prime = {
 | 
						||
      intelBusId = "PCI:0:2:0";
 | 
						||
      nvidiaBusId = "PCI:10:0:0";
 | 
						||
      sync.enable = true;
 | 
						||
    };
 | 
						||
  };
 | 
						||
 | 
						||
  system.stateVersion = "25.11"; # Did you read the comment?
 | 
						||
 | 
						||
}
 |