trouble with static content (SOLVED)
deeztek
nginx-forum at forum.nginx.org
Mon Nov 8 11:56:02 UTC 2021
Hi,
Thanks a lot for the suggestions. I ended up following your recommendation
and I set the /admin location as follows which took care of it. Now I know
that you setup a location within a location:
location /admin/ {
index index.cfm;
location ~* .(?:ico|css|js|gif|jpe?g|png|woff2|map)$ {
root /var/www/html;
expires max;
add_header Pragma public;
add_header Cache-Control "public, must-revalidate,
proxy-revalidate";
}
proxy_pass http://localhost:8888/admin/;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
include /etc/nginx/snippets/auth.conf; # Activates Authelia for
specified route/location, please ensure you have setup the domain in your
configuration.yml
}
Posted at Nginx Forum: https://forum.nginx.org/read.php?2,292760,292767#msg-292767
More information about the nginx
mailing list