目录
概述
Config Server的Git仓库配置详解--搜索目录
远程配置
https://gitee.com/pmel/pig-config/
application.yml
profile: profile-default
foo/application.properties
profile=default-foo
bar-1/application.properties
profile=default-bar
搜索目录-application.ym
修改工程microservice-config-server的application.yml
application.yml
server:
port: 8080
spring:
cloud:
config:
server:
git:
# uri: https://git.oschina.net/it-much/config-repo-51cto-video # 公用
uri: https://gitee.com/pmel/pig-config/
search-paths: foo,bar*
# search-paths:
# - foo # foo路径
# - bar # bar路径
访问测试
http://localhost:8080/application/default
说明:
1)从上面可以看出,有从3个文件中读取数据
==============================
QQ群:143522604
群里有相关资源
欢迎和大家一起学习、交流、提升!
==============================