• 카테고리

    질문 & 답변
  • 세부 분야

    백엔드

  • 해결 여부

    해결됨

config server 설정파일관리 폴더 설정

21.12.29 13:25 작성 조회수 1.37k

0

spring: application: name: configServer profiles: active: native cloud: config: server: native: search-locations: file:\\\C:\test # git: # uri: file:\\\C:\git-local-repo #local repository
 
 
config server에서 local repository 폴더를 깃이 관리하지 않고 사용하려고 합니다. local에서 config server를 구동시키면 잘 돌아가는데 server에서 config server를 구동시키면 아래와 같은 에러가 발생합니다. If you are using the git profile, you need to set a Git URI in your configuration. If you have set spring.cloud.config.server.bootstrap=true, you need to use a composite configuration. 어떻게 해결해야 할까요?

답변 2

·

답변을 작성해보세요.

0

코린이님의 프로필

코린이

질문자

2022.01.03

선생님 말씀대로 설정이 되어있었지만 계속해서 Config server 설정 에러가 발생해서 질문드렸습니다.

rachel ryu님의 프로필

rachel ryu

2022.08.21

혹시 해결하셨나요 ?

코린이님의 프로필

코린이

질문자

2022.08.21

해당 프로그램을 실행하는 커맨드 라인에서 문제를 발견했습니다. java -jar 파일.jar 로 실행하니까 에러가 사라졌습니다.

0

안녕하세요, 이도원입니다. 

Spring Cloud Config에서 Git 이외의 다른 repository 를 사용하실려면, spring.cloud.config.server 에 필요한 repository 설정으로 변경하시면 됩니다. 에러 메시지 중 git url을 요구하는 걸로 봐서, spring.cloud.config.server 설정이 git으로 되어 있는 것 같습니다. 

spring:
cloud:
config:
server:
# git:
# uri: https://github.com/joneconsulting/spring-cloud-config
native:
search-locations: file:///Users/dowonlee/Desktop/Work/native-file-repo

감사합니다.