Answer the question
In order to leave comments, you need to log in
Why doesn't 2 proxy_pass work?
This instruction clearly states that you can add more than one proxy_pass via location /***
https://www.digitalocean.com/community/tutorials/h...
I did just that. Launched elementary 2 Noda services, on different ports, each of which returns a phrase.
server {
listen 80;
listen [::]:80;
server_name мой.домен;
location / {
proxy_pass http://localhost:5000;
}
location /test {
proxy_pass http://localhost:5001;
}
}
/
мой.домен
one should return to me at the address, and мой.домен/test
another at the address.
Answer the question
In order to leave comments, you need to log in
Does your application on localhost:5001 expect the request to come to /test and not / ?
I'm 99% sure not.
I recommend reading the documentation in particular after "The request URI is passed to the server like this ".
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question