103 lines
2.2 KiB
YAML
103 lines
2.2 KiB
YAML
|
# Nacos帮助文档: https://nacos.io/zh-cn/docs/concepts.html
|
||
|
# Nacos认证信息
|
||
|
# 指定的配置
|
||
|
spring:
|
||
|
profiles:
|
||
|
active: local
|
||
|
|
||
|
---
|
||
|
#默认环境(预生产部署环境)
|
||
|
spring:
|
||
|
config:
|
||
|
activate:
|
||
|
on-profile: pre-production
|
||
|
cloud:
|
||
|
nacos:
|
||
|
discovery:
|
||
|
# 服务注册地址
|
||
|
server-addr: ai-nacos:8848
|
||
|
config:
|
||
|
# 配置中心地址
|
||
|
server-addr: ai-nacos:8848
|
||
|
# 配置文件格式
|
||
|
file-extension: yml
|
||
|
# 共享配置
|
||
|
shared-configs:
|
||
|
- application.${spring.cloud.nacos.config.file-extension}
|
||
|
|
||
|
---
|
||
|
|
||
|
#默认环境(jenkins部署环境)
|
||
|
spring:
|
||
|
config:
|
||
|
activate:
|
||
|
on-profile: dev
|
||
|
cloud:
|
||
|
nacos:
|
||
|
discovery:
|
||
|
# 服务注册地址
|
||
|
server-addr: ai-nacos:8848
|
||
|
config:
|
||
|
# 配置中心地址
|
||
|
server-addr: ai-nacos:8848
|
||
|
# 配置文件格式
|
||
|
file-extension: yml
|
||
|
# 共享配置
|
||
|
shared-configs:
|
||
|
- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
||
|
|
||
|
---
|
||
|
|
||
|
#localhost部署环境
|
||
|
spring:
|
||
|
config:
|
||
|
activate:
|
||
|
on-profile: local
|
||
|
cloud:
|
||
|
nacos:
|
||
|
discovery:
|
||
|
# 服务注册地址
|
||
|
server-addr: 127.0.0.1:8848
|
||
|
config:
|
||
|
# 配置中心地址
|
||
|
server-addr: 127.0.0.1:8848
|
||
|
# 配置文件格式
|
||
|
file-extension: yml
|
||
|
# 共享配置
|
||
|
shared-configs:
|
||
|
- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
||
|
|
||
|
|
||
|
---
|
||
|
#使用的远程的nacos在本地跑
|
||
|
spring:
|
||
|
config:
|
||
|
activate:
|
||
|
on-profile: remote_nacos
|
||
|
cloud:
|
||
|
nacos:
|
||
|
discovery:
|
||
|
# 服务注册地址
|
||
|
server-addr: 192.168.3.210:8848
|
||
|
# # 命名空间
|
||
|
# # 分组名称
|
||
|
# group: LOCAL_GROUP
|
||
|
config:
|
||
|
# 配置中心地址
|
||
|
server-addr: 192.168.3.210:8848
|
||
|
# # 命名空间
|
||
|
|
||
|
# # 分组名称
|
||
|
# group: LOCAL_GROUP
|
||
|
# 配置文件格式
|
||
|
file-extension: yml
|
||
|
# 共享配置
|
||
|
shared-configs:
|
||
|
#- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
||
|
- application.${spring.cloud.nacos.config.file-extension}
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|