I've found the problem. Thank you everybody for the tip about nginx -T The web app that I use "forge" to deploy servers seemed to add another redirect hidden inside of /etc/nginx/forge-conf/before/ssl_redirect.conf which was redirecting port 80 example.com to https://example.com My server block was correct, it was just this file that was adding an additional redirect. Thanks agaby Lebod - Nginx Mailing List - English
Echo Arief, Thanks for the reply. My complete set up is below. The only difference is the use of "example.com" instead of the domain for privacy reasons.I was really hoping that a gracious person would just point out the mistake in the set up if there is one... server { listen 80; listen 443 ssl; server_name example.com ***IP Address***; return 301 https://www.example.com$by Lebod - Nginx Mailing List - English
Thank you for the reply Francis, I have only 1 server {} with "example.com". I have one server block that listens on ports 80 and 443 to example.com and redirects to https://www.example.com like this: server { listen 80; listen 443 ssl; server_name example.com ***IP Address***; return 301 https://www.example.com$request_uri; } Is that not correct? Thank you v mby Lebod - Nginx Mailing List - English
Thanks for the tip Francis but Nginx -T doesn't give me a clue at all. Would you know what specifically I can change to fix this? Thank you so muchby Lebod - Nginx Mailing List - English
itpp2012 Wrote: ------------------------------------------------------- > Lebod Wrote: > ------------------------------------------------------- > > Thank you for the reply; > > > > If we did this: > > > > server { > > listen 80; > > -listen 443 ssl; > > server_name example.com ***IP Address***; > > return 301 https://by Lebod - Nginx Mailing List - English
Thank you for the reply; If we did this: server { listen 80; -listen 443 ssl; server_name example.com ***IP Address***; return 301 https://www.example.com$request_uri; } Wouldn't this stop https://example.com from re-directing to https://www.example.com then ?by Lebod - Nginx Mailing List - English
Hi everybody, I'm having an issue with our site. We're trying to redirect all traffic of http://example.com to https://www.example.com. Testing out our site, what happens is that http://example.com redirects to https://example.com which then redirects to https://www.example.com We also get an error: nginx -t nginx: conflicting server name "example.com" on 0.0.0.0:80, ignoredby Lebod - Nginx Mailing List - English
I'd prefer to get logrotate working correctly. What are the permissions of the files under /var/log/nginx supposed to be ?by Lebod - How to...
I've been researching this for a couple of weeks now and have been unable to rectify the problem. Even on a new Ubuntu 14.0.4 install when you rotate logs, nginx will start giving you permission denied errors for the log files such as: 2015/08/04 22:37:09 23365#0: open() "/var/log/nginx/error.log" failed (13: Permission denied) After logrotate, you get empty Nginx log files. Log fiby Lebod - How to...