limit_conn_zone $binary_remote_addr zone=perip:10m;
limit_conn_zone $server_name zone=perserver:10m;
log_format  main  '$http_origin $remote_user $time_iso8601 $request '
		'$status $body_bytes_sent "http_referer"'
		'"$http_user_agent" "$http_x_forwarded_for"';
access_log D:/pcdn/.pear/var/log/httpd/access.log main;
server {
	listen 1026;
	listen 49152 ssl;
	server_name _;

	ssl_certificate D:/pcdn/etc/pear/pear_httpd/ca_certs/prfog.com/prfog.com.crt;
	ssl_certificate_key D:/pcdn/etc/pear/pear_httpd/ca_certs/prfog.com/prfog.com.key;
	location / {
		limit_conn perip 5;
		limit_conn perserver 32;
		proxy_pass http://127.0.0.1:4999;
		proxy_set_header  Host  $host;
		proxy_set_header  X-Real-IP  $remote_addr;
		proxy_set_header  X-Forwarded-For $proxy_add_x_forwarded_for;
	}
}
server {
	listen 4998;
	server_name _;

	location / {
		allow 127.0.0.1;
		deny all;
		proxy_pass http://127.0.0.1:4999;
		proxy_set_header  Host  $host;
		proxy_set_header  X-Real-IP  $remote_addr;
		proxy_set_header  X-Forwarded-For $proxy_add_x_forwarded_for;
	}
}
