What cause the error for this http/https wordpress configuration file?

Reinis Rozitis r at roze.lv
Thu Aug 27 18:54:17 UTC 2015

> I can not open any link except http://example.com/readme.txt with 
> following
server block.
> Any tips?

How did you come up with such configuration in first place?

Second what exact response you get when opening something else (besides the 
readme.txt) and what does the access/error log contain for particular 
request - it should indicate the reason you can't open the particular url - 
depending on the response/http status it might be different thing (you have 
quite many location/deny blocks also 3rd party modules which could block the 
requests, the php backend might not be correctly configured (or just down) 

If unsure what the resulting config actually does I would start with a more 
simple version (bare server{} just with a php backend definition).

I mean a lot of your current configuration doesn't make sense or is 

Just for example you have:

if ($request_method = POST) {
        set $skip_cache 1;

and then:
fastcgi_cache_bypass $skip_cache;
fastcgi_cache_methods GET HEAD;

Where fastcgi_cache_methods default value allready is only GET and HEAD 
therefore the particular if() is not necessary nor the cache_methods setting 


More information about the nginx mailing list