# Turn off upload buffering in proxy mode

**URL:** <https://www.ruby-forum.com/t/turn-off-upload-buffering-in-proxy-mode/186900>\
**Category:** NGINX\
**Created:** [April 14, 2010, 12:32am UTC](https://www.ruby-forum.com/t/turn-off-upload-buffering-in-proxy-mode/186900 "2010-04-14T00:32:59Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Vincent\_MAUGE](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/v/e68b1a/32.png) [@Vincent\_MAUGE](https://www.ruby-forum.com/u/Vincent_MAUGE)\
**Post date:** [April 14, 2010, 12:32am UTC](https://www.ruby-forum.com/t/turn-off-upload-buffering-in-proxy-mode/186900/1 "2010-04-14T00:32:59Z")

</div>

Hey,

I setup a nginx as reverse proxy + SSL negotiation in front of apache  
servers. The setup works find and the configuration is quiet easy and  
efficient (url loadblancing, access rules).  
But I am facing an issue with upload; as nginx buffer the post request  
on local disk before transmit the request to upstream server, I need  
lot of storage on my server to handle space and io. Is there a way to  
deactivate upload buffering streaming directly the file and reduce the  
impact of upload on the server ?  
For now, I just find old request on the mailing list with the same  
subject but no usefull answer (“perhaps in the future”) or the same  
feature but for download (proxy\_buffering parameter in  
NginxHttpProxyModule).

Regards,

Vincent

---

<div class="post-metadata">

**Author:** ![Vincent\_MAUGE](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/v/e68b1a/32.png) [@Vincent\_MAUGE](https://www.ruby-forum.com/u/Vincent_MAUGE)\
**Post date:** [April 16, 2010, 4:26am UTC](https://www.ruby-forum.com/t/turn-off-upload-buffering-in-proxy-mode/186900/2 "2010-04-16T04:26:23Z")

</div>

> I am having a heck of a time, how did you setup SSL in nginx to proxy out to  
> Apache?

I use the following vhost :

upstream upstream-server {  
server 192.168.1.1:80;  
server 192.168.1.2:80;  
}

server {

```
    listen XX.XX.XX.XX:80;
    server_name foo.test.com;

    access_log /var/www/foo.test.com/logs/access.log;
    error_log /var/www/foo.test.com/logs/error.log;

    location / {
            proxy_pass http://upstream-server;
            include /etc/nginx/proxy.conf;
    }

```

}

server {

```
    listen XX.XX.XX.XX:443;
    server_name foo.test.com;

    ssl on;
    ssl_certificate 

```

/var/www/foo.test.com/certif/foo.test.com.chained.crt;  
ssl\_certificate\_key  
/var/www/foo.test.com/certif/foo.test.com.key;

```
    access_log /var/www/foo.test.com/logs/access.log;
    error_log /var/www/foo.test.com/logs/error.log;

    location / {
            proxy_pass http://upstream-server;
            include /etc/nginx/proxy.conf;
            proxy_set_header X-Forwarded-Protocol https;
    }

```

}

Regards,

Vincent
