From 6e12406e30b263ea7ce49a784c85f5a727b5fc8a Mon Sep 17 00:00:00 2001 From: Robin Gloster Date: Thu, 16 Feb 2017 22:43:49 +0100 Subject: [PATCH] Revert "nginx: Format the config file" This reverts commit e362a3d5c94ba379d428fbd2cc40470719a61556. See #22883 --- .../services/web-servers/nginx/default.nix | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/nixos/modules/services/web-servers/nginx/default.nix b/nixos/modules/services/web-servers/nginx/default.nix index aa11a5d5e80a..9e93e56b9c2c 100644 --- a/nixos/modules/services/web-servers/nginx/default.nix +++ b/nixos/modules/services/web-servers/nginx/default.nix @@ -16,20 +16,7 @@ let ) cfg.virtualHosts; enableIPv6 = config.networking.enableIPv6; - configFile = pkgs.runCommand "nginx.conf" { - inherit configFileUnformatted; - passAsFile = [ "configFileUnformatted" ]; - # configFileUnformatted is created locally, therefore so should this be. - preferLocalBuild = true; - allowSubstitutes = false; - } '' - cp ${configFileUnformatted} nginx.conf - chmod u+w nginx.conf - ${pkgs.nginx-config-formatter}/bin/nginxfmt nginx.conf - cp nginx.conf $out - ''; - - configFileUnformatted = pkgs.writeText "nginx.unformatted.conf" '' + configFile = pkgs.writeText "nginx.conf" '' user ${cfg.user} ${cfg.group}; error_log stderr; daemon off;