引入Nacos服务注册与发现
This commit is contained in:
@@ -2,8 +2,10 @@ package com.cxyxiaomo.epp;
|
||||
|
||||
import org.springframework.boot.SpringApplication;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
|
||||
|
||||
@SpringBootApplication
|
||||
@EnableDiscoveryClient
|
||||
public class Gateway {
|
||||
public static void main(String[] args) {
|
||||
SpringApplication.run(Gateway.class, args);
|
||||
|
@@ -6,6 +6,9 @@ spring:
|
||||
application:
|
||||
name: microservice-gateway
|
||||
cloud:
|
||||
nacos:
|
||||
discovery:
|
||||
server-addr: 127.0.0.1:8848
|
||||
gateway:
|
||||
discovery:
|
||||
locator:
|
||||
|
Reference in New Issue
Block a user