discoveryservice-eureka
라는 프로젝트를 생성한다
3개 항목을 추가한다.
생성된 -application에 @EnableEurekaServer을 설정해준다.
@SpringBootApplication
@EnableEurekaServer
public class DiscoveryserviceEurekaApplication {
public static void main(String[] args) {
SpringApplication.run(DiscoveryserviceEurekaApplication.class, args);
}
}
server:
port: 8761
spring:
application:
name: discoveryservice
cloud:
config:
uri: http://127.0.0.1:8888
name: ecommerce
eureka:
client:
register-with-eureka: false
fetch-registry: false
localhost:8761 접속하여 해당 화면이 뜨면 생성 및 설정 완료