2 { config, lib, pkgs, ... }:
5 cfg = config.services.urserver;
8 options.services.urserver.enable = lib.mkEnableOption (lib.mdDoc "urserver");
10 config = lib.mkIf cfg.enable {
12 networking.firewall = {
13 allowedTCPPorts = [ 9510 9512 ];
14 allowedUDPPorts = [ 9511 9512 ];
17 systemd.user.services.urserver = {
19 Server for Unified Remote: The one-and-only remote for your computer.
21 wantedBy = [ "graphical-session.target" ];
22 partOf = [ "graphical-session.target" ];
23 after = [ "network.target" ];
27 ${pkgs.urserver}/bin/urserver --daemon
30 ${pkgs.procps}/bin/pkill urserver
33 Restart = "on-failure";