Skip to content

Commit

Permalink
解决java 微服务发布时,端口冲突的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
yanjie.miao committed Oct 8, 2018
1 parent 6a2fda4 commit 983f5db
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 8 deletions.
9 changes: 7 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,7 @@
## 忽略models文件夹
*/node_modules/
## 忽略models文件夹
*/node_modules/
.idea/workspace.xml
.idea/modules.xml
.idea/misc.xml
.idea/docker-node.iml
node-client/package-lock.json
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ linux下部署注意: mesher的配置有两种方式
## windows下运行:

第一 配置mesher
可参考https://support.huaweicloud.com/bestpractice-servicestage/servicestage_bestpractice_0048.html
mesher下载地址:https://cse-bucket.obs.myhwclouds.com/Mesher/mesher-1.4.12-windows-amd64.zip
meshe配置可参考https://support.huaweicloud.com/bestpractice-servicestage/servicestage_bestpractice_0048.html
conf/chassis.yaml的listenAddress改为注册中心的地址。
microservice.yaml中的APPLICATION_ID最好和provider的APPLICATION_ID相同。

运行mesher
mesher-1.3.3-windows-amd64\start.bat

Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ services:
build: ./java-provider
restart: always
ports:
- 8080:8080
- 8383:8090
node-client:
build: ./node-client
restart: always
Expand Down
6 changes: 3 additions & 3 deletions java-provider/src/main/resources/microservice.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ servicecomb:
chain:
Provider: {}
highway:
address: 0.0.0.0:7777
address: 0.0.0.0:8191
rest:
address: 0.0.0.0:8080
address: 0.0.0.0:8090
service:
registry:
address: http://192.168.1.101:30100
address: http://10.0.1.252:30100
autodiscovery: false

0 comments on commit 983f5db

Please sign in to comment.