anchor.diff:    };
   
     config = mkIf cfg.enable {
  -    services.phpfpm.poolConfigs = mkIf (cfg.pool == "${poolName}") {
  -      "${poolName}" = ''
  -        listen = "${phpfpmSocketName}"
  -        listen.owner = nginx
  -        listen.group = nginx
  -        listen.mode = 0600
  -        user = icingaweb2
  -        pm = dynamic
  -        pm.max_children = 75
  -        pm.start_servers = 2
  -        pm.min_spare_servers = 2
  -        pm.max_spare_servers = 10
  -      '';
  +    services.phpfpm.pools = mkIf (cfg.pool == "${poolName}") {
  +      "${poolName}" = {
  +        socketName = "${poolName}";
  +        phpPackage = pkgs.php;
  +        user = "icingaweb2";
  +        group = "icingaweb2";
  +        extraConfig = ''
  +          listen.owner = ${config.services.nginx.user}
  +          listen.group = ${config.services.nginx.group}
  +          listen.mode = 0600
  +          pm = dynamic
  +          pm.max_children = 75
  +          pm.start_servers = 2
  +          pm.min_spare_servers = 2
  +          pm.max_spare_servers = 10
  +        '';
  +      };
       };
   
       services.phpfpm.phpOptions = mkIf (cfg.pool == "${poolName}")
  
positive.code: { config, lib, pkgs, ... }: with lib; let
    cfg = config.services.icingaweb2;
    poolName = "icingaweb2";
    phpfpmSocketName = "/var/run/phpfpm/${poolName}.sock";
  
    defaultConfig = {
      global = {
  
negative.code:       group = "icingaweb2";
        isSystemUser = true;
      };
      users.users.nginx = {
        extraGroups = [ "icingaweb2" ];
      };
    };
  }
  