1

I have the following nginx config file

server {
    location / {
        include uwsgi_params
        uwsgi_pass my-main-app:8000;
    }
    location /foo/ {
        include uwsgi_params
        uwsgi_pass my-secondary-app:8001;
    }
}

When I visit example.com/foo the server does a request to my-secondary-app:8001/foo

But instead I'd like that when I visit example.com/foo the server makes a request to my-secondary-app:8001/ (without the /foo)

The my-secondary-app is a Flask application.

Is there a way I can do this only modifying the nginx file?

Thanks in regard!

0 Answers0