1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
events { worker_connections 256; } http { access_log off; sendfile on; upstream api { server api01:8080; server api02:8080; } server { listen 9999; location / { proxy_pass http://api; proxy_read_timeout 30; } } }