Allow certain urls to be available on HTTP too when redirecting everything to HTTPS
- by Ashfame
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?