![](/img/trans.png)
[英]Spring Cloud Config Server: error: No such label: master
[英]spring cloud config server - No such label: master
我的云配置服务器正在返回属性文件,但现在我看到以下错误。 请你让我知道如何解决这个问题?
这部署在关键的云代工环境中。
{
"timestamp": 1464375520539
"status": 404
"error": "Not Found"
"exception": "org.springframework.cloud.config.server.environment.NoSuchLabelException"
"message": "No such label: master"
"path": "/couchbase-data/dev"
}
应用程序.yml
---
spring:
cloud:
config:
server:
git:
uri: https://github.company.com/username/ordering-properties
username: username
password: "{cipher}03f0ac5cc43d913bbd45155f852d1e5c88542878491a1fc89185feea93a40084"
search-paths: couchbase-data
security:
basic:
enabled: true
user:
name: ordering_config
password: "{cipher}dc56acf65f93b5485c87de1a9965e76a2d0b642a0839027deffdbc35f922746f"
清单文件.yml
---
name: orderingconfigserver
memory: 2048M
instances: 1
timeout: 180
env:
ENCRYPT_KEY: ORDERING
部署应用程序后,对端点的第一次点击返回以下错误:
{
"timestamp": 1464377154415
"status": 500
"error": "Internal Server Error"
"exception": "java.lang.IllegalStateException"
"message": "Cannot clone or checkout repository"
"path": "/couchbase-data/dev"
}
如果您的 git repo 的主分支名称为“main”而不是“master”,我建议您添加一个新属性来更改默认标签,如下所示:
spring.cloud.config.server.git.default-label=main
检查此链接以获取更多信息。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.