SpringCloudConfig浣跨敤
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了SpringCloudConfig浣跨敤相关的知识,希望对你有一定的参考价值。
鏍囩锛?a href='http://www.mamicode.com/so/1/default' title='default'>default host img service 涓嬫媺 work mic yml nbsp
config 鏈嶅姟绔?/p>
1. maven 娣诲姞
<dependency> <groupId>org.springframework.cloud</groupId> <artifactId>spring-cloud-config-server</artifactId> </dependency>
2. 鍚姩绫绘坊鍔?娉ㄨВ
@EnableConfigServer
3.yml閰嶇疆鏂囦欢
eureka: client: service-url: defaultZone: http://10.10.10.103:8761/eureka # 娉ㄥ唽涓績 spring: application: name: CONFIG cloud: config: server: git: # git config 閰嶇疆鏂囦欢 鍦板潃 uri: https://github.com/qukaige/config-repo.git # 閰嶇疆鏂囦欢涓嬫媺鍒版湰鍦扮殑鏂囦欢澶逛腑 basedir: C:/SpringCloud/config/basedir # 鐢ㄦ埛鍚嶅瘑鐮? username: 123 password: 1qaz rabbitmq: # mq鍦板潃 host: 10.10.10.103 port: 5672 username: guest password: guest
4. git 鐨勯厤缃枃浠?/p>
以上是关于SpringCloudConfig浣跨敤的主要内容,如果未能解决你的问题,请参考以下文章