Hello,
I’ve already asked the similar question, but it doesn’t seem that I solved the problem properly.
My goal:
www.pincoin.co.kr/assets/images/shop/naver/code/*
This URL(static image files) must be served via HTTP.
i.e) http://www.pincoin.co.kr/assets/images/shop/naver/code/1.jpg
and it works for the first time right after I deleted browser caches/cookies.
If I visit http://pincoin.co.kr, https://pincoin.co.kr and browse some pages, it does not work.
When I retrieve the static image file, I see the error message: ERR_TOO_MANY_REDIRECTS
My settings:
-
DNS
- A record for www to IP address
-
Crypto
- SSL = Full (strict)
- Always Use HTTPS = Off
- HTTP Strict Transport Security (HSTS) = Disabled
- Automatic HTTPS Rewrites = Off
-
Page Rules
-
www.pincoin.co.kr/assets/images/shop/naver/code/*
SSL: Off, Automatic HTTPS Rewrites: Off -
http://pincoin.co.kr/
Forwarding URL: (Status Code: 301 - Permanent Redirect, Url: 대한민국 1등 온라인상품권쇼핑몰 : 핀코인) -
https://pincoin.co.kr/
Forwarding URL: (Status Code: 301 - Permanent Redirect, Url: https://www.pincoin.co.kr/)
-
-
My nginx settings:
It doesn’t have any “return redirect” statement. There’re only two server blocks for 80/443 with “www.pincoin.co.kr”.
server { listen 80; server_name www.pincoin.co.kr; charset utf-8; root /path/to/repo; location /assets/ { access_log off; log_not_found off; location ~ \.(jpeg|jpg|png|gif) { expires 30d; add_header Cache-Control "public"; } location ~ \.(css|js) { expires -1; add_header Cache-Control "public"; } } } server { listen 443 ssl; server_name www.pincoin.co.kr; charset utf-8; root /path/to/repo; location /assets/ { access_log off; log_not_found off; location ~ \.(jpeg|jpg|png|gif) { expires 30d; add_header Cache-Control "public"; } location ~ \.(css|js) { expires -1; add_header Cache-Control "public"; } } location / { include /etc/nginx/uwsgi_params; uwsgi_param HTTP_X_FORWARDED_PROTO $scheme; uwsgi_pass kr-co-pincoin-www-django; } }
So, do I have to delete page rules “Forwarding URL to www”?
Thank you for your help.