Allow certain urls to be available on HTTP too when redirecting everything to HTTPS
Posted
by
Ashfame
on Server Fault
See other posts from Server Fault
or by Ashfame
Published on 2013-06-24T15:29:08Z
Indexed on
2013/06/24
16:24 UTC
Read the original article
Hit count: 219
nginx
Right now, I redirected all the HTTP urls to HTTPS using this code in my nginx config:
server {
server_name domain.com
listen 80;
location /asset/ {
# make files under asset directory (recursively) be available over HTTP too
}
location / {
rewrite ^ https://$server_name$request_uri? permanent;
}
}
How can I make files under asset directory (recursively) be available over HTTP too?
© Server Fault or respective owner