zx 3 years ago
parent
commit
f475671e84

+ 4 - 4
pom.xml

@@ -71,10 +71,10 @@
             <version>3.4.2</version>
         </dependency>
 
-        <dependency>
-            <groupId>org.springframework.boot</groupId>
-            <artifactId>spring-boot-starter-security</artifactId>
-        </dependency>
+<!--        <dependency>-->
+<!--            <groupId>org.springframework.boot</groupId>-->
+<!--            <artifactId>spring-boot-starter-security</artifactId>-->
+<!--        </dependency>-->
 
         <!--swagger-->
         <dependency>

+ 2 - 2
src/main/resources/application-dev.yml

@@ -42,7 +42,7 @@ openfeign:
   TmsTruckFeign:
     url: ${TMSTRUCKFEIGN_URL:172.16.33.162:8008}
   TmsshipFeign:
-    url: ${TMSSHIPFEIGN_URL:172.16.33.162:8003}
+    url: ${TMSSHIPFEIGN_URL:localhost:8003}
   WMSHFeign:
     url: ${WMSHFEIGN_URL:172.16.33.162:8013}
   WMSFeign:
@@ -50,7 +50,7 @@ openfeign:
   OMSFeign:
     url: ${OMSFEIGN_URL:172.16.33.162:8016}
   RmsFeign:
-    url: ${RMSFEIGN_HRL:172.16.33.162:8014}
+    url: ${RMSFEIGN_HRL:localhost:8014}
   JoinFeign:
     url: ${JOINFEIGN_URL:172.16.33.162:8006}
   OTMSFeign:

+ 1 - 1
src/main/resources/application-prod.yml

@@ -33,7 +33,7 @@ openfeign:
   OMSFeign:
     url: ${OMSFEIGN_URL:172.16.33.166:8095}
   RmsFeign:
-    url: ${RMSFEIGN_URL:172.16.33.166:8060}
+    url: ${RMSFEIGN_URL:localhost:8060}
   JoinFeign:
     url: ${JOINFEIGN_URL:172.16.33.166:8066}
   OTMSFeign:

+ 5 - 2
src/main/resources/bootstrap.yml

@@ -1,7 +1,7 @@
 api.version: api/v1
 spring:
   profiles:
-    include: ${SPRING_PROFILES:prod}
+    include: ${SPRING_PROFILES:dev}
   jackson:
     date-format: yyyy-MM-dd HH:mm:ss
     time-zone: GMT+8
@@ -12,16 +12,19 @@ spring:
   mvc:
     static-path-pattern:
 
-
 #eureka设置
 eureka:
   client:
     service-url:
       defaultZone: http://root:root@${EUREKA_HOST:172.16.33.166}:${EUREKA_PORT:8081}/eureka/
+    register-with-eureka: false #表示向EurekaServer注册自己 默认为true
+    fetch-registry: false #是否从EurekaServer抓取已有的注册信息,默认为true,单节点无所谓,集群必须设置为true才能配合ribbon使用负载均衡
+
   instance:
     prefer-ip-address: true
     status-page-url: http://${spring.cloud.client.ip-address}:${server.port}/swagger-ui.html#/
     instance-id: ${spring.cloud.client.ip-address}:${server.port}
+
 genxml:
   pth: com/agit
 cache: