mirror of
https://github.com/nezhahq/nezha.git
synced 2025-01-22 12:48:14 -05:00
🐛 fix: 修复一直报警SSL证书问题
This commit is contained in:
parent
4b6740e6e0
commit
cb207580cf
@ -182,6 +182,12 @@ URL 里面也可放置占位符,请求时会进行简单的字符串替换。
|
||||
|
||||
## 变更日志
|
||||
|
||||
`dashboard 0.2.2` `agent 0.2.2`
|
||||
|
||||
- `dashboard 0.2.2`
|
||||
|
||||
- 修复一直报警SSL证书问题
|
||||
|
||||
- `agent 0.2.2`
|
||||
|
||||
- 修复双栈IP只能获取到v6的问题 #61
|
||||
|
@ -26,7 +26,7 @@ var SortedServerList []*model.Server
|
||||
|
||||
var ServerLock sync.RWMutex
|
||||
|
||||
var Version = "v0.2.1"
|
||||
var Version = "v0.2.2"
|
||||
|
||||
func ReSortServer() {
|
||||
SortedServerList = []*model.Server{}
|
||||
|
@ -30,9 +30,10 @@ func (s *NezhaHandler) ReportTask(c context.Context, r *pb.TaskResult) (*pb.Rece
|
||||
// 证书错误提醒
|
||||
errMsg = r.GetData()
|
||||
} else {
|
||||
var oldSSLCert = strings.Split(last.Data, "|")
|
||||
var splits = strings.Split(r.GetData(), "|")
|
||||
// 证书变更提醒
|
||||
if last.Data != "" && last.Data != splits[0] {
|
||||
if last.Data != "" && oldSSLCert[0] != splits[0] {
|
||||
errMsg = fmt.Sprintf(
|
||||
"SSL证书变更,旧:%s,新:%s。",
|
||||
last.Data, splits[0])
|
||||
|
Loading…
Reference in New Issue
Block a user