diff options
author | tv <tv@krebsco.de> | 2020-06-02 23:35:17 +0200 |
---|---|---|
committer | tv <tv@krebsco.de> | 2020-06-02 23:35:17 +0200 |
commit | 09c9f8f7fb04be39390b6f65966789c1bf6333e5 (patch) | |
tree | b0cb0f718b40517b0645a38169e67b1088566f64 /lass/2configs/home-media.nix | |
parent | 09e620c79b70e495e9651e8e5c1b160dd1b5fb8d (diff) | |
parent | 211e2ca6b9a1d8b4dd92071065b0b595123fe282 (diff) |
Merge remote-tracking branch 'prism/master'
Diffstat (limited to 'lass/2configs/home-media.nix')
-rw-r--r-- | lass/2configs/home-media.nix | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/lass/2configs/home-media.nix b/lass/2configs/home-media.nix new file mode 100644 index 000000000..7e10aed34 --- /dev/null +++ b/lass/2configs/home-media.nix @@ -0,0 +1,23 @@ +with import <stockholm/lib>; +{ pkgs, ... }: +{ + users.users.media = { + isNormalUser = true; + uid = genid_uint31 "media"; + extraGroups = [ "video" "audio" ]; + }; + + services.xserver.displayManager.lightdm.autoLogin = { + enable = true; + user = "media"; + }; + + hardware.pulseaudio.configFile = pkgs.writeText "pulse.pa" '' + .include ${pkgs.pulseaudioFull}/etc/pulse/default.pa + load-module module-native-protocol-tcp auth-ip-acl=127.0.0.1;10.42.0.0/24 auth-anonymous=1 + ''; + + krebs.iptables.tables.filter.INPUT.rules = [ + { predicate = "-p tcp --dport 4713"; target = "ACCEPT"; } # pulseaudio + ]; +} |