diff --git a/projects/Infrastructure/Infrastructure.csproj b/projects/Infrastructure/Infrastructure.csproj
index 7b652cca..350e921e 100644
--- a/projects/Infrastructure/Infrastructure.csproj
+++ b/projects/Infrastructure/Infrastructure.csproj
@@ -15,7 +15,7 @@
runtime; build; native; contentfiles; analyzers; buildtransitive
-
+
diff --git a/projects/IoT.Shared/IoT.Shared.csproj b/projects/IoT.Shared/IoT.Shared.csproj
index 1dd3dd27..4ae6758c 100644
--- a/projects/IoT.Shared/IoT.Shared.csproj
+++ b/projects/IoT.Shared/IoT.Shared.csproj
@@ -18,7 +18,7 @@
-
+
diff --git a/projects/Version.cs b/projects/Version.cs
index ad4fd2a4..b92ee678 100644
--- a/projects/Version.cs
+++ b/projects/Version.cs
@@ -1,4 +1,4 @@
using System.Reflection;
[assembly: AssemblyVersion("1.0.0.0")]
-[assembly: AssemblyInformationalVersion("1.0.0.0807d2")]
\ No newline at end of file
+[assembly: AssemblyInformationalVersion("1.0.0.0810d1")]
\ No newline at end of file
diff --git a/publish/src/linux-x64/publish/docker-compose.override.yml b/publish/src/linux-x64/publish/docker-compose.override.yml
index eb1221c2..1f4156d6 100644
--- a/publish/src/linux-x64/publish/docker-compose.override.yml
+++ b/publish/src/linux-x64/publish/docker-compose.override.yml
@@ -1,12 +1,10 @@
#docker-compose up -d
version: "3.8"
services:
- desktop:
+ website:
volumes:
- - ../../../../projects/WebMVC/wwwroot:/usr/share/nginx/html
- mobile:
- volumes:
- - ../../../../projects/WebSPA/wwwroot:/usr/share/nginx/html
+ - ../../../../projects/WebMVC/wwwroot:/usr/share/nginx/html/desktop
+ - ../../../../projects/WebSPA/wwwroot:/usr/share/nginx/html/mobile
gateway:
volumes:
- ./docker/conf/gateway/nginx.development.conf:/etc/nginx/nginx.conf
\ No newline at end of file
diff --git a/publish/src/linux-x64/publish/docker-compose.prod.yml b/publish/src/linux-x64/publish/docker-compose.prod.yml
index 97385e62..9adbe7c9 100644
--- a/publish/src/linux-x64/publish/docker-compose.prod.yml
+++ b/publish/src/linux-x64/publish/docker-compose.prod.yml
@@ -54,36 +54,3 @@ services:
networks:
default:
ipv4_address: 172.172.0.90
- webmvc:
- image: nginx:1.18
- restart: always
- environment:
- TZ: "Asia/Shanghai"
- ports:
- - 5001:80
- volumes:
- - ./apps/WebMVC/wwwroot:/usr/share/nginx/html
- - ./docker/log/webmvc:/var/log/nginx
- networks:
- default:
- ipv4_address: 172.172.0.110
- webspa:
- image: nginx:1.18
- restart: always
- environment:
- TZ: "Asia/Shanghai"
- ports:
- - 5002:80
- volumes:
- - ./apps/WebSPA/wwwroot:/usr/share/nginx/html
- - ./docker/log/webspa:/var/log/nginx
- networks:
- default:
- ipv4_address: 172.172.0.120
- nginx:
- depends_on:
- - usercenter
- - iotcenter
- - jobserver
- - webmvc
- - webspa
diff --git a/publish/src/linux-x64/publish/docker-compose.yml b/publish/src/linux-x64/publish/docker-compose.yml
index f8c0797b..db48a004 100644
--- a/publish/src/linux-x64/publish/docker-compose.yml
+++ b/publish/src/linux-x64/publish/docker-compose.yml
@@ -18,8 +18,8 @@ services:
networks:
default:
ipv4_address: 172.172.0.101
-#web sites
- desktop:
+#web site
+ website:
image: nginx:1.18
restart: always
environment:
@@ -28,33 +28,16 @@ services:
- 80:80
- 443:443
volumes:
- - ./docker/conf/desktop/nginx.conf:/etc/nginx/nginx.conf
- - ./docker/log/desktop:/var/log/nginx
- - ./apps/WebMVC/wwwroot:/usr/share/nginx/html
+ - ./docker/conf/website/nginx.conf:/etc/nginx/nginx.conf
+ - ./docker/log/website:/var/log/nginx
+ - ./apps/WebMVC/wwwroot:/usr/share/nginx/html/desktop
+ - ./apps/WebSPA/wwwroot:/usr/share/nginx/html/mobile
depends_on:
- minio
- mysql
networks:
default:
ipv4_address: 172.172.0.10
- mobile:
- image: nginx:1.18
- restart: always
- environment:
- TZ: "Asia/Shanghai"
- ports:
- - 81:80
- - 4430:443
- volumes:
- - ./docker/conf/mobile/nginx.conf:/etc/nginx/nginx.conf
- - ./docker/log/mobile:/var/log/nginx
- - ./apps/WebSPA/wwwroot:/usr/share/nginx/html
- depends_on:
- - minio
- - mysql
- networks:
- default:
- ipv4_address: 172.172.0.11
#gateway
gateway:
image: nginx:1.18
diff --git a/publish/src/linux-x64/publish/docker/conf/gateway/nginx.conf b/publish/src/linux-x64/publish/docker/conf/gateway/nginx.conf
index ee69e0e6..227eb0f7 100644
--- a/publish/src/linux-x64/publish/docker/conf/gateway/nginx.conf
+++ b/publish/src/linux-x64/publish/docker/conf/gateway/nginx.conf
@@ -45,22 +45,22 @@ http {
}
location ^~ /UserCenter/ {
- proxy_pass http://172.172.0.70/UserCenter/;
+ proxy_pass http://172.172.0.70:8010/UserCenter/;
}
location ^~ /IoTCenter/ {
- proxy_pass http://172.172.0.80/IoTCenter/;
+ proxy_pass http://172.172.0.80:8011/IoTCenter/;
}
location ^~ /IoTCenter/hub {
- proxy_pass http://172.172.0.80/IoTCenter/hub;
+ proxy_pass http://172.172.0.80:8011/IoTCenter/hub;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
location ^~ /JobServer/ {
- proxy_pass http://172.172.0.90/JobServer/;
+ proxy_pass http://172.172.0.90:8013/JobServer/;
}
error_page 500 502 503 504 /50x.html;
diff --git a/publish/src/linux-x64/publish/docker/conf/mobile/nginx.conf b/publish/src/linux-x64/publish/docker/conf/mobile/nginx.conf
deleted file mode 100644
index 5a3f7ca4..00000000
--- a/publish/src/linux-x64/publish/docker/conf/mobile/nginx.conf
+++ /dev/null
@@ -1,71 +0,0 @@
-#user nobody;
-worker_processes 1;
-
-#error_log logs/error.log;
-#error_log logs/error.log notice;
-#error_log logs/error.log info;
-
-#pid logs/nginx.pid;
-events {
- worker_connections 1024;
-}
-
-http {
- include mime.types;
- default_type application/octet-stream;
- sendfile on;
- keepalive_timeout 65;
-
- server {
- listen 0.0.0.0:80;
- server_name localhost;
-
- location / {
- root /usr/share/nginx/html;
- index index.html;
- }
-
- location ^~ /dfs/ {
- proxy_set_header Host $host;
- proxy_set_header X-Real-IP $remote_addr;
- proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
- proxy_pass http://172.172.0.12;
- }
-
- location ^~ /live/ {
- proxy_pass http://172.172.0.12;
- }
-
- location ^~ /video/ {
- proxy_pass http://172.172.0.12;
- }
-
- location ^~ /influxdb/ {
- proxy_pass http://172.172.0.12;
- }
-
- location ^~ /UserCenter/ {
- proxy_pass http://172.172.0.12;
- }
-
- location ^~ /IoTCenter/ {
- proxy_pass http://172.172.0.12;
- }
-
- location ^~ /IoTCenter/hub {
- proxy_pass http://172.172.0.12;
- proxy_http_version 1.1;
- proxy_set_header Upgrade $http_upgrade;
- proxy_set_header Connection "upgrade";
- }
-
- location ^~ /JobServer/ {
- proxy_pass http://172.172.0.12;
- }
-
- error_page 500 502 503 504 /50x.html;
- location = /50x.html {
- root html;
- }
- }
-}
\ No newline at end of file
diff --git a/publish/src/linux-x64/publish/docker/conf/desktop/nginx.conf b/publish/src/linux-x64/publish/docker/conf/website/nginx.conf
similarity index 77%
rename from publish/src/linux-x64/publish/docker/conf/desktop/nginx.conf
rename to publish/src/linux-x64/publish/docker/conf/website/nginx.conf
index 4ec7e4af..a5b92f89 100644
--- a/publish/src/linux-x64/publish/docker/conf/desktop/nginx.conf
+++ b/publish/src/linux-x64/publish/docker/conf/website/nginx.conf
@@ -16,31 +16,35 @@ http {
sendfile on;
keepalive_timeout 65;
+ upstream gateway {
+ server 172.172.0.12;
+ }
+
server {
listen 0.0.0.0:80;
server_name localhost;
location / {
- root /usr/share/nginx/html;
- index index.html;
+ root /usr/share/nginx/html/desktop;
if ($http_user_agent ~* "(mobile|android|ipad|iphone|ipod|tablet)") {
- return 302 http://$host:81/;
+ root /usr/share/nginx/html/mobile;
}
+ index index.html;
}
- location ^~ /dfs/ {
+ location ^~ /dfs/ {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
- proxy_pass http://172.172.0.12;
+ proxy_pass http://gateway;
}
location ^~ /live/ {
- proxy_pass http://172.172.0.12;
+ proxy_pass http://gateway;
}
location ^~ /video/ {
- proxy_pass http://172.172.0.12;
+ proxy_pass http://gateway;
}
location ^~ /influxdb/ {
@@ -56,14 +60,14 @@ http {
}
location ^~ /IoTCenter/hub {
- proxy_pass http://172.172.0.12;
+ proxy_pass http://gateway;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
location ^~ /JobServer/ {
- proxy_pass http://172.172.0.12;
+ proxy_pass http://gateway;
}
error_page 500 502 503 504 /50x.html;