Nginx: Large Scale Applications

Load Balancing

Useful for large applications running multiple instances.

upstream node_js {
  server 0.0.0.0:3000;
  server 0.0.0.0:4000;
  server 123.131.121.122;
}

server {
  listen 80;
  server_name yourdomain.com;
  
  location / {
    proxy_pass http://node_js;
  }
}

Leave a Reply

Your email address will not be published. Required fields are marked *