./configure --with-http_stub_status_module --with-http_ssl_module --with-stream --with-stream_ssl_preread_module --with-stream_ssl_module
make && make install
编辑nginx.conf
stream {
map $ssl_preread_server_name $name {
default backend;
}
upstream backend {
server 10.6.207.252:26335;
}
server {
listen 1800;
proxy_connect_timeout 1s;
proxy_timeout 3s;
ssl_preread on;
proxy_pass $name;
}
}
http {
include mime.types;
default_type application/octet-stream;
#log_format main '$remote_addr - $remote_user [$time_local] "$request" '
# '$status $body_bytes_sent "$http_referer" '
# '"$http_user_agent" "$http_x_forwarded_for"';
#access_log logs/access.log main;
sendfile on;
#tcp_nopush on;
#keepalive_timeout 0;
keepalive_timeout 65;
#gzip on;
server {
listen 80;
server_name localhost;
#charset koi8-r;
#access_log logs/host.access.log main;
location / {
root html;
.......