Skip to content

Commit f320bf6

Browse files
authored
fix(tandoor): Update Nginx with upstream configuration (#177)
1 parent 91691d0 commit f320bf6

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

tandoor/nginx/recipes.conf

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,15 @@
1+
# set paths to writable location as non-root by default
2+
proxy_temp_path /tmp/proxy_temp;
3+
client_body_temp_path /tmp/client_temp;
4+
fastcgi_temp_path /tmp/fastcgi_temp;
5+
uwsgi_temp_path /tmp/uwsgi_temp;
6+
scgi_temp_path /tmp/scgi_temp;
7+
18
server {
29
listen 80;
310
server_name localhost;
411

5-
client_max_body_size 128M;
12+
client_max_body_size 512M;
613

714
# serve media files
815
location /recipes/media {
@@ -22,12 +29,15 @@ server {
2229
# pass requests for dynamic content to gunicorn
2330
location / {
2431
proxy_set_header Host $http_host;
25-
proxy_pass http://unix:/run/tandoor.sock;
32+
proxy_pass http://unix:/tmp/tandoor.sock;
33+
34+
# param needed by django allauth sessions to log IP
2635
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
2736
proxy_set_header X-Script-Name /recipes;
2837
proxy_cookie_path / /recipes;
2938

30-
error_page 502 /errors/http502.html;
39+
# disabled for now because it redirects to the error page and not back, also not showing html
40+
#error_page 502 /errors/http502.html;
3141
}
3242

3343
location /recipes/errors/ {

0 commit comments

Comments
 (0)