Answer the question
In order to leave comments, you need to log in
How to configure nginx to load css via proxy_pass?
We needed to make it so that when accessing a specific folder of the site, information from our other project was loaded. It turned out to be quite simple
location ^~ /domain-lp/ {
proxy_pass http://domain.ru/lp/;
}
location ^~ /domain-sm/ {
proxy_pass http://domain.ru/sm/;
}
location ^~ /domain-sm/ {
proxy_pass http://domain.ru/sm/;
proxy_set_header Host domain.ru;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
<base>
before adding css
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question