From c4bd79eaab73cde521dad2d7e6b25c0b94391a58 Mon Sep 17 00:00:00 2001 From: Igor Pashev Date: Wed, 1 Feb 2017 21:41:26 +0300 Subject: php-fpm: use simple mapAttrs' Instead of folding, since we produce single member attribute set. --- modules/apps/php-fpm.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'modules/apps') diff --git a/modules/apps/php-fpm.nix b/modules/apps/php-fpm.nix index cdc83c6..8501208 100644 --- a/modules/apps/php-fpm.nix +++ b/modules/apps/php-fpm.nix @@ -6,7 +6,7 @@ let filter isAttrs isBool ; inherit (lib) - concatStringsSep filterAttrs foldl hasPrefix mapAttrs' mapAttrsToList + concatStringsSep filterAttrs hasPrefix mapAttrs' mapAttrsToList mkDefault mkIf mkOption ; inherit (lib.types) @@ -82,7 +82,8 @@ let then "--php-ini ${cfg.php-ini}" else "--no-php-ini" ); in { - "php-fpm-${name}" = { + name = "php-fpm-${name}"; + value = { description = "PHP FastCGI Process Manager (${name})"; after = [ "local-fs.target" ]; wantedBy = [ "multi-user.target" ]; @@ -187,7 +188,7 @@ in { config = mkIf ({} != instances) { nixsap.apps.logrotate.conf = mapAttrs' mkLogRotate instances; nixsap.system.users.daemons = users; - systemd.services = foldl (a: b: a//b) {} (mapAttrsToList mkService instances); + systemd.services = mapAttrs' mkService instances; }; } -- cgit v1.2.3