Mei99
2019-09-02 19:05:01 +08:00
nginx.conf:
worker_processes auto;
pid /run/nginx.pid;
include /etc/nginx/modules-enabled/*.conf;
worker_rlimit_nofile 65535;
events {
use epoll;
worker_connections 65535;
#multi_accept on;
}
http {
upstream tomcat{
server 192.168.50.166:8080;
server 192.168.50.99:8080;
keepalive 20480;
}
server{
listen 8080;
location / {
proxy_pass http://tomcat;
proxy_http_version 1.1;
proxy_set_header Connection "";
}
}
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 15;
types_hash_max_size 2048;
server_tokens off;
client_header_buffer_size 4k;
client_max_body_size 10m;
# server_names_hash_bucket_size 64;
# server_name_in_redirect off;
include /etc/nginx/mime.types;
default_type application/octet-stream;
##
# SSL Settings
##
ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # Dropping SSLv3, ref: POODLE
ssl_prefer_server_ciphers on;
##
# Logging Settings
##
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log;