What I'm Doing

To improve the efficiency of python website under nginx, it’s better to use tcp connection rather than proxy_pass with http protocol.

nginx conf

edit /etc/nginx/site-enabled/default or add a new file in site-enabled folder

server{
    listen 80;
    server_name abc.com
    location /api {
        uwsgi_pass 127.0.0.1:3015;
        include uwsgi_params;
        access_log /var/log/api.log;
    }
}

... Read More