Re: map configuration

2017-07-04 Thread foxgab
that means, if the value of $http_upgrade is null or that variable doesn't exist, the value of $connection_upgrade will set to "close", or it will set to "upgrade" in the other cases. the $http_upgrade is the value of the "Upgrade" header in the client request. Posted at Nginx Forum: https://for

Re: proxy_set_header directives don't inherit from father context

2017-07-04 Thread nanaya
Hi, On Wed, Jul 5, 2017, at 14:41, foxgab wrote: > i expected the X-Forwarded-For and X-Forwarded-Proto header will be set, > but > it didn't. > what happend? > Quite a few of additive configs (proxy_set_header, add_header) are only inherited if there's no same directive set at current block.

Re: map configuration

2017-07-04 Thread foxgab
why no just pass the $http_upgrade and $http_connection headers to the backend? like conf bellow: proxy_set_header Upgrade $http_upgrade proxy_set_header Connection $http_Connection and if i set the Connection header to "upgrade" permanently, does it make any harm? Posted at Nginx Forum: https:/

proxy_set_header directives don't inherit from father context

2017-07-04 Thread foxgab
i found if i didn't configure any proxy_set_header directives in a context, it will inherit those directives from father context automatic, but if i set one in current context, the inheritance won't work. my configration is like bellow: http { proxy_set_header X-Forwarded-For $remote_addr;

Re: Is there a module that can prettify the page output before it is send to the requesting client?

2017-07-04 Thread vfclists .
On 4 July 2017 at 18:45, Peter Booth wrote: > Depends on your definition of pretty and what you want to achieve. Are you > looking for pretty for a human reader or for a browser? > > Google's pagespeed module comes in both apache and nginx flavors and > applies a bunch of page optimization transf

Re: Nginx Tuning

2017-07-04 Thread lists
I'd suggest the online guides on anti-DDoSing for NGINX. They cover limiting the number of connections, etc. Of course in reality these schemes would just limit some some kid in the basement from flooding your server rather than a real DDoS attack. But better than nothing, plus what is in those

Re: Is there a module that can prettify the page output before it is send to the requesting client?

2017-07-04 Thread Peter Booth
Depends on your definition of pretty and what you want to achieve. Are you looking for pretty for a human reader or for a browser? Google's pagespeed module comes in both apache and nginx flavors and applies a bunch of page optimization transformations to the page and embedded resources. I've s

Re: Nginx Tuning

2017-07-04 Thread Peter Booth
What is your ultimate goal here? What are you wanting to prevent? Sent from my iPhone > On Jul 4, 2017, at 4:01 AM, guruprasads wrote: > > Hi, > > I am trying to tune nginx server. > I want to restrict number of client connection per server and restrict > bandwidth. > I tried > worker_connect

Re: map configuration

2017-07-04 Thread Michael Salmon
The map is similar to $connection_upgrade = ($http_upgrade == '') ? 'close' : 'upgrade'; Each line in a map is a match and a value with default being used if nothing matches. /Michael Salmon SE KI73 03 366 (OLC: 9FFVCX53+C5Q8) +46 722 184 909 > On 4 Jul 2017, at 16:37:37, Dan Edwards wrote: >

map configuration

2017-07-04 Thread Dan Edwards
Hello: Need help understanding this piece of Nginx configuration: === map $http_upgrade $connection_upgrade { default upgrade; '' close; } === What does the last line mean? TIA, -- -Dan Edwards- ___ nginx mailing list nginx@nginx.org htt

Re: Does Nginx supports If-Range ?

2017-07-04 Thread Nelson Marcos
Thanks Zhang and Maxim! I'm checking how to fix that on my backend. Kind, NM 2017-07-04 9:21 GMT-03:00 Maxim Dounin : > Hello! > > On Mon, Jul 03, 2017 at 05:09:28PM -0300, Nelson Marcos wrote: > > > I don't know if it is an expected behaviour or a bug: > > > > > > Scenario 1(OK): If I perform

Re: Nginx Tuning

2017-07-04 Thread Maxim Dounin
Hello! On Tue, Jul 04, 2017 at 04:01:44AM -0400, guruprasads wrote: > Hi, > > I am trying to tune nginx server. > I want to restrict number of client connection per server and restrict > bandwidth. > I tried > worker_connections 2; > for max connections in nginx.conf file. > but its connectin

Re: Nginx Tuning

2017-07-04 Thread Richard Stanway
You shouldn't be changing worker_connections, this is the total number of connections (of any type) permitted per worker. Take a look at the documentation at http://nginx.org/en/docs/ Of interest to you are http://nginx.org/en/docs/http/ngx_http_limit_conn_module.html and http://nginx.org/en/docs

Re: Does Nginx supports If-Range ?

2017-07-04 Thread Maxim Dounin
Hello! On Mon, Jul 03, 2017 at 05:09:28PM -0300, Nelson Marcos wrote: > I don't know if it is an expected behaviour or a bug: > > > Scenario 1(OK): If I perform a request *with the header Range*, Nginx > serves the *partial content(HTTP 206)*. > > Scenario 2 (NOT OK): If I perform a request *

Is there a module that can prettify the page output before it is send to the requesting client?

2017-07-04 Thread vfclists .
Is there a module that can prettify the HTML before it gets sent to the client? Some think like that must be run before the zip stage. -- Frank Church === http://devblog.brahmancreations.com ___ nginx mailing list nginx@nginx.org ht

Nginx Tuning

2017-07-04 Thread guruprasads
Hi, I am trying to tune nginx server. I want to restrict number of client connection per server and restrict bandwidth. I tried worker_connections 2; for max connections in nginx.conf file. but its connecting only after worker_connection value set to 7. my conf file look like below. user ngin

prxy_buffering

2017-07-04 Thread charlesparasa
I am trying to check the functionality of proxy_buffering . can you please provide me with some sample test scenario. Basically I want to visualise the behaviours of nginx when proxy_buffering is on and off . And also please share what are the parameter gets effected when proxy_buffering is on or