From a5ce76bc4183c5d3b113fc62ba978d983060b969 Mon Sep 17 00:00:00 2001 From: liuchen <23082234@qq.com> Date: Tue, 6 Feb 2024 10:32:51 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9=E7=AB=AF=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.production | 4 ++-- .env.test | 4 ++-- nginx.conf | 11 +++++++++++ 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/.env.production b/.env.production index fe5163c..66e1490 100644 --- a/.env.production +++ b/.env.production @@ -1,8 +1,8 @@ # port -VITE_DEV_PORT = '25100' +VITE_DEV_PORT = '25101' # production path -VITE_BASE_URL = 'http://10.62.193.15:25100/api' +VITE_BASE_URL = 'http://10.62.193.15:25101/api' # 租户开关 VITE_APP_TENANT_ENABLE=true \ No newline at end of file diff --git a/.env.test b/.env.test index b7f4a92..b62d0ab 100644 --- a/.env.test +++ b/.env.test @@ -1,8 +1,8 @@ # port -VITE_DEV_PORT = '8080' +VITE_DEV_PORT = '25101' # production path -VITE_BASE_URL = 'http://dev.ccwin-in.com:25100/api' +VITE_BASE_URL = 'http://dev.ccwin-in.com:25101/api' # 租户开关 VITE_APP_TENANT_ENABLE=true \ No newline at end of file diff --git a/nginx.conf b/nginx.conf index 194b7ea..0e14ef0 100644 --- a/nginx.conf +++ b/nginx.conf @@ -26,10 +26,21 @@ http { gzip_types text/plain application/javascript text/css application/xml text/javascript image/jpeg image/gif image/png; gzip_vary on; gzip_disable "MSIE [1-6]\."; + upstream sfms3.0 { + server localhost:25110 weight=10 max_fails=3 fail_timeout=10s; + } server { listen 25101; server_name_in_redirect off; server_name dev.ccwin-in.com; + location /api/ { + proxy_pass http://sfms3.0/; + proxy_next_upstream http_500 http_502 http_503 http_504 error timeout invalid_header; + proxy_set_header X-Forwared-For $proxy_add_x_forwarded_for; + proxy_set_header Host $http_host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $http_x_forwarded_for; + } location / { proxy_cache my_zone; proxy_cache_valid 200 304 12h;