this sorta worked
This commit is contained in:
		
							parent
							
								
									ab2413d3c6
								
							
						
					
					
						commit
						96acd705cb
					
				| @ -55,50 +55,6 @@ in | ||||
|         ]; | ||||
|       }; | ||||
|       # lib.my-namespace.home.stream-tools.enable = true; | ||||
|       programs.gamescope.enable = true; | ||||
|       programs.steam = { | ||||
|         enable = true; | ||||
|         remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play | ||||
|         dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server | ||||
|         localNetworkGameTransfers.openFirewall = true; # Open ports in the firewall for Steam Local Network Game Transfers | ||||
| 
 | ||||
|         gamescopeSession = { | ||||
|           enable = true; | ||||
|           env = { | ||||
|             # WLR_RENDERER = "vulkan"; | ||||
|             # DXVK_HDR = "1"; | ||||
|             ENABLE_GAMESCOPE_WSI = "1"; | ||||
|             WINE_FULLSCREEN_FSR = "1"; | ||||
|             # Games allegedly prefer X11 | ||||
|             SDL_VIDEODRIVER = "x11"; | ||||
|           }; | ||||
|           args = [ | ||||
|             "--xwayland-count 2" | ||||
|             "--expose-wayland" | ||||
| 
 | ||||
|             "-e" # Enable steam integration | ||||
|             "--steam" | ||||
| 
 | ||||
|             # "--adaptive-sync" | ||||
|             # "--hdr-enabled" | ||||
|             # "--hdr-itm-enable" | ||||
| 
 | ||||
|             # External monitor | ||||
|             "--prefer-output DP-3" | ||||
|             "--output-width 1920" | ||||
|             "--output-height 1080" | ||||
|             "-r 172" | ||||
| 
 | ||||
|             # Laptop display | ||||
|             # "--prefer-output eDP-1" | ||||
|             # "--output-width 2560" | ||||
|             # "--output-height 1600" | ||||
|             # "-r 120" | ||||
|              | ||||
|             "--prefer-vk-device 10de:1b81" # lspci -nn | grep VGA | ||||
|           ]; | ||||
|         }; | ||||
|       }; | ||||
| 
 | ||||
|       # Open ports in the firewall. | ||||
|       networking.firewall.allowedTCPPorts = [ | ||||
|  | ||||
| @ -4,10 +4,13 @@ | ||||
|   # Enable OpenGL | ||||
|   hardware.graphics = { | ||||
|     enable = true; | ||||
|     extraPackages = with pkgs; [ nvidia-vaapi-driver ]; | ||||
|   }; | ||||
| 
 | ||||
|   # Load nvidia driver for Xorg and Wayland | ||||
|   #boot.extraModulePackages = [ config.boot.kernelPackages.nvidia_x11 ]; | ||||
|   # boot.extraModulePackages = [ config.boot.kernelPackages.nvidia_x11 ]; | ||||
|   boot.extraModulePackages = [ config.boot.kernelPackages.nvidia_x11_vulkan_beta ]; | ||||
| 
 | ||||
|   boot.kernelParams = [ | ||||
|    "nvidia-drm.fbdev=1" | ||||
|    "nvidia-drm.modeset=1" | ||||
| @ -18,7 +21,15 @@ | ||||
|     "nouveau"    | ||||
|   ]; | ||||
|   services.xserver.videoDrivers = [ "nvidia" ]; | ||||
|   boot.initrd.kernelModules = [ "nvidia" "nvidia-drm" ]; | ||||
|   boot.initrd.kernelModules = [  | ||||
|     "nvidia"  | ||||
|     "nvidia-drm" | ||||
|     "nvidia-modeset" | ||||
|     "nvidia-uvm" | ||||
|     "nvidia_modeset" | ||||
|     "nvidia_uvm" | ||||
|     "i2c-nvidia_gpu" | ||||
|     ]; | ||||
|   #boot.initrd.kernelModules = [ "nvidia" ]; | ||||
|    | ||||
| 
 | ||||
| @ -50,7 +61,9 @@ | ||||
|     nvidiaSettings = true; | ||||
| 
 | ||||
|     # Optionally, you may need to select the appropriate driver version for your specific GPU. | ||||
|     package = config.boot.kernelPackages.nvidiaPackages.beta; | ||||
|     # package = config.boot.kernelPackages.nvidiaPackages.beta; | ||||
|     package = config.boot.kernelPackages.nvidiaPackages.vulkan_beta; | ||||
| 
 | ||||
|   }; | ||||
|   # users.users.andreas = { | ||||
|   #  extraGroups = [ "video" "render" ]; | ||||
|  | ||||
							
								
								
									
										72
									
								
								systems/x86_64-linux/drivebystation-nix/steam.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										72
									
								
								systems/x86_64-linux/drivebystation-nix/steam.nix
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,72 @@ | ||||
| { | ||||
|   # Snowfall Lib provides a customized `lib` instance with access to your flake's library | ||||
|   # as well as the libraries available from your flake's inputs. | ||||
|   lib,  | ||||
|   # An instance of `pkgs` with your overlays and packages applied is also available. | ||||
|   pkgs,  | ||||
|   # You also have access to your flake's inputs. | ||||
|   inputs,  | ||||
|   # Additional metadata is provided by Snowfall Lib. | ||||
|   # The namespace used for your flake, defaulting to "internal" if not set. | ||||
|   namespace,  | ||||
|   # The system architecture for this host (eg. `x86_64-linux`). | ||||
|   system,  | ||||
|   # The Snowfall Lib target for this system (eg. `x86_64-iso`). | ||||
|   target,  | ||||
|   # A normalized name for the system target (eg. `iso`). | ||||
|   format,  | ||||
|   # A boolean to determine whether this system is a virtual target using nixos-generators. | ||||
|   virtual,  | ||||
|   # An attribute map of your defined hosts. | ||||
|   systems,  | ||||
|   # All other arguments come from the system system. | ||||
|   config | ||||
| , ... | ||||
| }:{ | ||||
|   config = { | ||||
|     programs.gamescope.enable = true; | ||||
|     programs.steam = { | ||||
|       enable = true; | ||||
|       remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play | ||||
|       dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server | ||||
|       localNetworkGameTransfers.openFirewall = true; # Open ports in the firewall for Steam Local Network Game Transfers | ||||
| 
 | ||||
|       gamescopeSession = { | ||||
|         enable = true; | ||||
|         env = { | ||||
|           WLR_RENDERER = "vulkan"; | ||||
|           DXVK_HDR = "1"; | ||||
|           ENABLE_GAMESCOPE_WSI = "1"; | ||||
|           WINE_FULLSCREEN_FSR = "1"; | ||||
|           # Games allegedly prefer X11 | ||||
|           SDL_VIDEODRIVER = "x11"; | ||||
|         }; | ||||
|         args = [ | ||||
|           "--xwayland-count 1" | ||||
|           "--expose-wayland" | ||||
| 
 | ||||
|           "-e" # Enable steam integration | ||||
|           "--steam" | ||||
| 
 | ||||
|           # "--adaptive-sync" | ||||
|           # "--hdr-enabled" | ||||
|           # "--hdr-itm-enable" | ||||
| 
 | ||||
|           # External monitor | ||||
|           "--prefer-output DP-3" | ||||
|           "--output-width 1920" | ||||
|           "--output-height 1080" | ||||
|           "-r 172" | ||||
| 
 | ||||
|           # Laptop display | ||||
|           # "--prefer-output eDP-1" | ||||
|           # "--output-width 2560" | ||||
|           # "--output-height 1600" | ||||
|           # "-r 120" | ||||
|            | ||||
|           "--prefer-vk-device 10de:1b81" # lspci -nn | grep VGA | ||||
|         ]; | ||||
|       }; | ||||
|     }; | ||||
|   }; | ||||
| } | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user