lol

nixos/matrix-synapse: add readOnly serviceUnit option

This is useful to configure services dependent on matrix-synapse regardless
of whether workers are enabled or not.

+13
+13
nixos/modules/services/matrix/synapse.nix
··· 296 296 services.matrix-synapse = { 297 297 enable = mkEnableOption (lib.mdDoc "matrix.org synapse"); 298 298 299 + serviceUnit = lib.mkOption { 300 + type = lib.types.str; 301 + readOnly = true; 302 + description = lib.mdDoc '' 303 + The systemd unit (a service or a target) for other services to depend on if they 304 + need to be started after matrix-synapse. 305 + 306 + This option is useful as the actual parent unit for all matrix-synapse processes 307 + changes when configuring workers. 308 + ''; 309 + }; 310 + 299 311 configFile = mkOption { 300 312 type = types.path; 301 313 readOnly = true; ··· 1021 1033 port = 9093; 1022 1034 }); 1023 1035 1036 + services.matrix-synapse.serviceUnit = if hasWorkers then "matrix-synapse.target" else "matrix-synapse.service"; 1024 1037 services.matrix-synapse.configFile = configFile; 1025 1038 services.matrix-synapse.package = wrapped; 1026 1039