home(steam): port to home

This commit is contained in:
514fpv 2024-01-07 21:50:42 +08:00
parent 50749ed595
commit 2081040e55
Signed by: koishi
SSH key fingerprint: SHA256:axz0uIzzY+5W19i7QOUuiw5LSqhKfCBKPf3L4xFRxLw
4 changed files with 56 additions and 23 deletions

14
home/steam/config.nix Normal file
View file

@ -0,0 +1,14 @@
{ pkgs
, lib
, config
, ... }: with lib; let
cfg = config.home.steam;
in mkIf cfg.enable {
hardware.steam-hardware.enable = true;
networking.firewall = {
allowedTCPPorts = [ 27015 27036 ];
allowedUDPPorts = [ 27015 ];
allowedUDPPortRanges = [ { from = 27031; to = 27036; } ];
};
}