16306: Move nginx temp dirs into a subdir.
authorTom Clegg <tom@curii.com>
Tue, 22 Dec 2020 21:15:21 +0000 (16:15 -0500)
committerTom Clegg <tom@curii.com>
Tue, 22 Dec 2020 21:15:21 +0000 (16:15 -0500)
When running as root, Nginx changes ownership of these temp dirs to
"nobody".  We also use the same TMPDIR for standalone passenger
processes, which run as www-data, so we need Nginx to leave it alone.

Arvados-DCO-1.1-Signed-off-by: Tom Clegg <tom@curii.com>

sdk/python/tests/nginx.conf

index cdca68dd6738e77ab65b6b0feb051708c1c939ba..a4336049f2447bd18cf396cbec0b76e7cdf69356 100644 (file)
@@ -11,11 +11,11 @@ http {
     '[$time_local] "$http_x_request_id" $server_name $status $body_bytes_sent $request_time $request_method "$scheme://$http_host$request_uri" $remote_addr:$remote_port '
     '"$http_referer" "$http_user_agent"';
   access_log "{{ACCESSLOG}}" customlog;
     '[$time_local] "$http_x_request_id" $server_name $status $body_bytes_sent $request_time $request_method "$scheme://$http_host$request_uri" $remote_addr:$remote_port '
     '"$http_referer" "$http_user_agent"';
   access_log "{{ACCESSLOG}}" customlog;
-  client_body_temp_path "{{TMPDIR}}";
-  proxy_temp_path "{{TMPDIR}}";
-  fastcgi_temp_path "{{TMPDIR}}";
-  uwsgi_temp_path "{{TMPDIR}}";
-  scgi_temp_path "{{TMPDIR}}";
+  client_body_temp_path "{{TMPDIR}}/nginx";
+  proxy_temp_path "{{TMPDIR}}/nginx";
+  fastcgi_temp_path "{{TMPDIR}}/nginx";
+  uwsgi_temp_path "{{TMPDIR}}/nginx";
+  scgi_temp_path "{{TMPDIR}}/nginx";
   upstream controller {
     server {{LISTENHOST}}:{{CONTROLLERPORT}};
   }
   upstream controller {
     server {{LISTENHOST}}:{{CONTROLLERPORT}};
   }