[nginx] P-Real-IP -> X-Real-IP
Signed-off-by: Yohann D'ANELLO <ynerant@crans.org>certbot_on_virtu
parent
9f97936635
commit
6054b7a545
|
@ -11,7 +11,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
return 302 http://{{ site.to }}$request_uri;
|
return 302 http://{{ site.to }}$request_uri;
|
||||||
|
@ -31,7 +31,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
return 302 https://{{ site.to }}$request_uri;
|
return 302 https://{{ site.to }}$request_uri;
|
||||||
|
@ -55,7 +55,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
return 302 http://{{ site.to }}$request_uri;
|
return 302 http://{{ site.to }}$request_uri;
|
||||||
|
@ -75,7 +75,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
return 302 https://{{ site.to }}$request_uri;
|
return 302 https://{{ site.to }}$request_uri;
|
||||||
|
|
|
@ -18,7 +18,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
return 302 https://$host$request_uri;
|
return 302 https://$host$request_uri;
|
||||||
|
@ -51,7 +51,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
proxy_pass http://{{ site.to }};
|
proxy_pass http://{{ site.to }};
|
||||||
|
|
|
@ -15,7 +15,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
return 302 http://{{ to }}$request_uri;
|
return 302 http://{{ to }}$request_uri;
|
||||||
|
@ -35,7 +35,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
return 302 https://{{ to }}$request_uri;
|
return 302 https://{{ to }}$request_uri;
|
||||||
|
|
|
@ -30,7 +30,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
return 302 https://{{ nginx.default_ssl_server }}$request_uri;
|
return 302 https://{{ nginx.default_ssl_server }}$request_uri;
|
||||||
|
@ -53,7 +53,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
return 302 http://{{ nginx.default_server }}$request_uri;
|
return 302 http://{{ nginx.default_server }}$request_uri;
|
||||||
|
@ -77,7 +77,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
return 302 https://$host$request_uri;
|
return 302 https://$host$request_uri;
|
||||||
|
@ -104,7 +104,7 @@ server {
|
||||||
{% for realip in nginx.real_ip_from %}
|
{% for realip in nginx.real_ip_from %}
|
||||||
set_real_ip_from {{ realip }};
|
set_real_ip_from {{ realip }};
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
real_ip_header P-Real-Ip;
|
real_ip_header X-Real-Ip;
|
||||||
|
|
||||||
{% if server.root is defined %}root {{ server.root }};{% endif %}
|
{% if server.root is defined %}root {{ server.root }};{% endif %}
|
||||||
{% if server.index is defined %}index {{ server.index|join(" ") }};{% endif %}
|
{% if server.index is defined %}index {{ server.index|join(" ") }};{% endif %}
|
||||||
|
|
Loading…
Reference in New Issue