spring cloud eureka作为办事注册中间,若何设置装备摆设eureka,来启动一个eureka实例呢,下面将具体介绍
打开intellij idea,建立spring boot项目
添加maven依靠,代码如下
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-netflix-eureka-server</artifactId>
</dependency>
添加@EnableEurekaServer注解,如下图所示
点窜application.properties设置装备摆设文件,设置sever.port
点击启动按钮,启动应用法式
拜候应用,打开eureka界面,如下图所示
0 篇文章
如果觉得我的文章对您有用,请随意打赏。你的支持将鼓励我继续创作!