<div dir="ltr">I think this problem is better solved allowing 80 to be open and a separate server block. Since i terminate from haproxy, from memory something like this, in the same vhost file. Obviously you can listen here on H/2 if you want to as well.<div><br></div><div>server {</div><div> <span style="background-color:rgb(43,43,43);color:rgb(169,183,198);font-family:"IBM Plex Mono";font-size:9pt">listen 80 default_server;</span></div><div><span style="background-color:rgb(43,43,43);color:rgb(169,183,198);font-family:"IBM Plex Mono";font-size:9pt"> server_name <a href="http://test.ppp.fr">test.ppp.fr</a>;</span></div><div><span style="background-color:rgb(43,43,43);color:rgb(169,183,198);font-family:"IBM Plex Mono";font-size:9pt"> return 301 https://$server_name$request_uri;</span></div><div>}</div><div><br></div><div>Best,<br>jeff</div></div><br><div class="gmail_quote"><div dir="ltr">On Mon, Sep 17, 2018 at 6:10 PM Pierre Couderc <<a href="mailto:pierre@couderc.eu">pierre@couderc.eu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I did use wrongly a 301 redirect....<br>
<br>
I have corrected now, but the redirect remains.<br>
<br>
I use wget :<br>
<br>
nous@pcouderc:~$ wget <a href="https://www.ppp.fr" rel="noreferrer" target="_blank">https://www.ppp.fr</a><br>
--2018-09-17 23:52:44-- <a href="https://www.ppp.fr/" rel="noreferrer" target="_blank">https://www.ppp.fr/</a><br>
Resolving <a href="http://www.ppp.fr" rel="noreferrer" target="_blank">www.ppp.fr</a> (<a href="http://www.ppp.fr" rel="noreferrer" target="_blank">www.ppp.fr</a>)... 2a01:e34:eeaf:c5f0::fee6:854e, <br>
78.234.252.95<br>
Connecting to <a href="http://www.ppp.fr" rel="noreferrer" target="_blank">www.ppp.fr</a> <br>
(<a href="http://www.ppp.fr" rel="noreferrer" target="_blank">www.ppp.fr</a>)|2a01:e34:eeaf:c5f0::fee6:854e|:443... connected.<br>
HTTP request sent, awaiting response... 301 Moved Permanently<br>
Location: <a href="https://test.ppp.fr/" rel="noreferrer" target="_blank">https://test.ppp.fr/</a> [following]<br>
--2018-09-17 23:52:44-- <a href="https://test.ppp.fr/" rel="noreferrer" target="_blank">https://test.ppp.fr/</a><br>
Resolving <a href="http://test.ppp.fr" rel="noreferrer" target="_blank">test.ppp.fr</a> (<a href="http://test.ppp.fr" rel="noreferrer" target="_blank">test.ppp.fr</a>)... 2a01:e34:eeaf:c5f0::fee6:854e, <br>
78.234.252.95<br>
Connecting to <a href="http://test.ppp.fr" rel="noreferrer" target="_blank">test.ppp.fr</a> <br>
(<a href="http://test.ppp.fr" rel="noreferrer" target="_blank">test.ppp.fr</a>)|2a01:e34:eeaf:c5f0::fee6:854e|:443... connected.<br>
HTTP request sent, awaiting response... 200 OK<br>
Length: unspecified [text/html]<br>
Saving to: ‘index.html.3’....<br>
<br>
In access.log :<br>
<br>
2a01:e34:eeaf:c5f0::feb1:b1c9 - - [18/Sep/2018:00:04:34 +0200] "GET / <br>
HTTP/2.0" 200 21511 "-" "Mozilla/5.0 (X11; Linux x86_64) <br>
AppleWebKit/537.36 (KHTML, like Gecko) Chrome/69.0.3497.81 Safari/537.36"<br>
2a01:e34:eeaf:c5f0::feb1:b1c9 - - [18/Sep/2018:00:04:34 +0200] "GET <br>
/fuveau.png HTTP/2.0" 404 271 "<a href="https://test.ppp.fr/" rel="noreferrer" target="_blank">https://test.ppp.fr/</a>" "Mozilla/5.0 (X11; <br>
Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/69.0.3497.81 <br>
Safari/537.36"<br>
<br>
<br>
I am pretty sure that I have removed the fatal redirect, and I have <br>
checked that the only 301 remaining are on port 80 :<br>
location / {<br>
return 301 https://$server_name$request_uri;<br>
}<br>
<br>
So I suppose there is a cache somewhere where nginx keeps its secret and <br>
fatal 301 ? How can I remove it ?<br>
<br>
Thanks<br>
<br>
PC<br>
_______________________________________________<br>
nginx mailing list<br>
<a href="mailto:nginx@nginx.org" target="_blank">nginx@nginx.org</a><br>
<a href="http://mailman.nginx.org/mailman/listinfo/nginx" rel="noreferrer" target="_blank">http://mailman.nginx.org/mailman/listinfo/nginx</a></blockquote></div>