mirror of
https://gitee.com/durcframework/SOP.git
synced 2025-08-11 21:57:56 +08:00
1.15.1
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
<dependency>
|
||||
<groupId>com.gitee.sop</groupId>
|
||||
<artifactId>sop-service-common</artifactId>
|
||||
<version>1.0.0-SNAPSHOT</version>
|
||||
<version>最新版本</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -17,15 +17,16 @@
|
||||
</dependency>
|
||||
```
|
||||
|
||||
- 配置文件添加eureka配置
|
||||
- 配置文件添加
|
||||
|
||||
```yaml
|
||||
eureka:
|
||||
port: 1111 # eureka端口号
|
||||
host: localhost # eureka地址
|
||||
client:
|
||||
serviceUrl:
|
||||
defaultZone: http://${eureka.host}:${eureka.port}/eureka/
|
||||
```properties
|
||||
server.port=2222
|
||||
# 服务名称
|
||||
spring.application.name=story-service
|
||||
# eureka注册中心
|
||||
eureka.client.serviceUrl.defaultZone=http://localhost:1111/eureka/
|
||||
# zookeeper配置
|
||||
spring.cloud.zookeeper.connect-string=localhost:2181
|
||||
```
|
||||
|
||||
- 在springboot启动类上添加`@EnableDiscoveryClient`
|
||||
|
Reference in New Issue
Block a user