From aa74d3e89ba4b3e678b1b491802e73a700e179eb Mon Sep 17 00:00:00 2001 From: Jakub Jirutka Date: Thu, 27 Apr 2017 12:43:00 +0200 Subject: [PATCH] Set *_temp_path location to $ServRoot/ Linux distributions build nginx with options like `--http-client-body-temp-path=` to set default location of directories for temporary files under /var/tmp/nginx or /var/lib/nginx. The problem is, when running tests as part of the package build process, these directories are not writtable. Therefore it's needed to override location of these directories in the generated nginx.conf. Upstream-Issue: https://github.com/openresty/test-nginx/pull/63 --- lib/Test/Nginx/Util.pm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/Test/Nginx/Util.pm b/lib/Test/Nginx/Util.pm index 6c2fab7c..0534cc5d 100644 --- a/lib/Test/Nginx/Util.pm +++ b/lib/Test/Nginx/Util.pm @@ -964,6 +964,12 @@ _EOC_ } print $out <<_EOC_; + + client_body_temp_path "$ServRoot/client_body_temp"; + proxy_temp_path "$ServRoot/proxy_temp"; + fastcgi_temp_path "$ServRoot/fastcgi_temp"; + scgi_temp_path "$ServRoot/scgi_temp"; + uwsgi_temp_path "$ServRoot/uwsgi_temp"; } $post_main_config