{ config, pkgs, lib, namespace, ... }: with lib; let name = "sunshine"; cfg = config.${namespace}.services.${name}; module = lib.${namespace}.mkModule { inherit config name; description = "Sunshine, a self-hosted game stream host for Moonlight"; options = { }; moduleConfig = { services.sunshine = { enable = true; openFirewall = cfg.openFirewall; autoStart = true; capSysAdmin = true; applications.apps = with pkgs; [ steam ]; }; }; }; in { imports = [ module ]; }