mirror of
https://github.com/mashirozx/Pixiv-Nginx.git
synced 2024-11-21 13:18:11 +08:00
proxy instead of rewrite
This commit is contained in:
parent
241d025459
commit
3d5ff59de0
@ -112,15 +112,22 @@ server {
|
||||
ssl_certificate_key ca/pixiv.net.key;
|
||||
|
||||
location / {
|
||||
rewrite ^/(.*)$ https://i.pixiv.re/$1 redirect;
|
||||
set $pximg_url i.pixiv.re;
|
||||
|
||||
#rewrite ^/(.*)$ https://$pximg_url/$1 redirect;
|
||||
|
||||
# proxy_pass https://i-pximg-net;
|
||||
# proxy_set_header Host $http_host;
|
||||
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
# proxy_set_header X-Real_IP $remote_addr;
|
||||
# proxy_set_header User-Agent $http_user_agent;
|
||||
# proxy_set_header Accept-Encoding '';
|
||||
# proxy_buffering off;
|
||||
|
||||
resolver 223.5.5.5;
|
||||
proxy_pass https://$pximg_url;
|
||||
proxy_set_header Host $pximg_url;
|
||||
proxy_ssl_server_name on;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Real_IP $remote_addr;
|
||||
proxy_set_header User-Agent $http_user_agent;
|
||||
proxy_set_header Accept-Encoding '';
|
||||
proxy_buffering off;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1 +1 @@
|
||||
12424
|
||||
4624
|
||||
|
Loading…
Reference in New Issue
Block a user