server { listen *:80 default_server; # e.g., listen 192.168.1.1:80; In most cases *:80 is a good idea listen [::]:80 default_server; server_tokens off; # don't show the version number, a security best practice # location / { # rewrite ^ https://$server_name$request_uri? permanent; # } location / { root /home/dev01/src/appros-serverd/serverd/www; index index.html index.htm; } location ~ /api/ { uwsgi_read_timeout 300; # Some requests take more than 30 seconds. uwsgi_connect_timeout 300; # Some requests take more than 30 seconds. uwsgi_pass unix:///run/uwsgi/app/serverd/socket; include uwsgi_params; } }