worker_processes 1;
events {
worker_connections 1024;
}
stream {
upstream app-ssh {
server 192.168.25.130:22;
}
upstream app-redis {
server 192.168.25.130:6379;
}
upstream app-nginx {
server 192.168.25.130:80;
}
upstream app-nginx-qa {
server 192.168.25.130:81;
}
upstream app-jenkins {
server 192.168.25.130:8080;
}
upstream app-java {
server 192.168.25.130:9888;
}
upstream app-java-qa {
server 192.168.25.130:9882;
}
upstream app-doc {
server 192.168.25.130:3000;
}
upstream db-ssh {
server 192.168.25.131:22;
}
upstream db-mysql {
server 192.168.25.131:3306;
}
upstream db-minio{
server 192.168.25.131:9000;
}
upstream minio-console{
server 192.168.25.131:9001;
}
upstream fsim-web {
server 192.168.25.132:9080;
}
upstream fsim-ssh {
server 192.168.25.132:22;
}
upstream fbtest-java {
server 192.168.25.130:9666;
}
upstream vostest-web {
server 192.168.25.130:82;
}
upstream fsim-mongo {
server 192.168.25.132:27017;
}
server {
listen 8380;
proxy_pass app-nginx;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 8382;
proxy_pass app-nginx-qa;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 8381;
proxy_pass app-jenkins;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 8388;
proxy_pass app-java;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 8398;
proxy_pass app-java-qa;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 8300;
proxy_pass app-doc;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 9022;
proxy_pass app-ssh;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 8379;
proxy_pass app-redis;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 9122;
proxy_pass db-ssh;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 8306;
proxy_pass db-mysql;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 9000;
proxy_pass db-minio;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 9001;
proxy_pass minio-console;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 9222;
proxy_pass fsim-ssh;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 7082;
proxy_pass vostest-web;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 7899;
proxy_pass fbtest-java;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 7099;
proxy_pass fsim-web;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
server {
listen 7098;
proxy_pass fsim-mongo ;
proxy_connect_timeout 1h;
proxy_timeout 1h;
}
}
http {
include mime.types;
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 /nginx-1.18.0/logs/access.log main;
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 65;
types_hash_max_size 4096;
default_type application/octet-stream;
server {
listen 9180;
server_name localhost;
location / {
root /app/immp/front/dist;
index index.html index.htm;
}
location /tripod {
proxy_pass http://172.26.100.158:9888;
}
location /immp {
proxy_pass http://172.26.100.158:9888;
}
error_page 404 /404.html;
location = /404.html {
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
}
}
}
标签:mongodb,redis,server,nginx,proxy,timeout,pass,1h,listen From: https://www.cnblogs.com/vzhangxk/p/16865480.html