
pid /nginx-config/nginx.pid;

daemon off;

worker_processes 6;

worker_rlimit_nofile 1047552;

worker_shutdown_timeout 10s ;

events {
	multi_accept        on;
	worker_connections  16384;
	use                 epoll;
}

http {
	....
	....
}

stream {
	
	variables_hash_bucket_size      256;
	variables_hash_max_size         2048;
	map_hash_max_size               2048;    
	map_hash_bucket_size            64;
	
	
	# TCP services
	
	upstream tcp-gateway-5443 {
		
		server 172.20.49.11:5443;
		server 172.20.49.15:5443;
		server 172.20.49.19:5443;
		server 172.20.49.18:5443;
		server 172.20.49.10:5443;
		server 172.20.49.23:5443;
		server 172.20.49.29:5443;
		server 172.20.49.34:5443;
		server 172.20.49.49:5443;
	}
	
	server {
		
		listen 10.255.210.131:3443  reuseport  ;
				
		listen [::]:3443  reuseport ipv6only=on  ;
		
		proxy_pass tcp-gateway-5443;
		
		proxy_timeout 600s;	
		proxy_next_upstream     on;
		proxy_next_upstream_timeout 600s;
		proxy_next_upstream_tries   3;
		
		proxy_protocol          on;
	}
}

