# Name    : nginx.conf
# Author  : Turing reference from LiuJinHui
# Date    : 2016-06-29 20:07:58
# Func    : Nginx Proxy 主配置文件
# Note    :
# Version : 1.0

user  easyops;
worker_processes      4;

error_log  log/error.log;
pid        log/nginx.pid;

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


stream {
    upstream command_server {
        server __SERVERIP__:5511;
    }
    upstream receiver {
        server __SERVERIP__:8820;
    }
    upstream download_server {
        server __SERVERIP__:80;
    }
    upstream download_server_https {
        server __SERVERIP__:443;
    }

    server {
        listen 5511;
        proxy_pass command_server;
    }
    server {
        listen 8820;
        proxy_pass receiver;
    }
    server {
        listen 80;
        proxy_pass download_server;
    }
    server {
        listen 443;
        proxy_pass download_server_https;
    }
}
