mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-24 16:03:43 +08:00
fix(lbagent): telegraf configuration panic (#22095)
This commit is contained in:
@@ -171,7 +171,9 @@ func (s *STelegraf) GetConfig(kwargs map[string]interface{}) string {
|
||||
"/run/onecloud/containerd/",
|
||||
"/var/lib/",
|
||||
}
|
||||
ignorePathSegments = append(ignorePathSegments, kwargs["server_path"].(string))
|
||||
if sp, ok := kwargs["server_path"]; ok {
|
||||
ignorePathSegments = append(ignorePathSegments, sp.(string))
|
||||
}
|
||||
for i := range ignorePathSegments {
|
||||
ignorePathSegments[i] = fmt.Sprintf("%q", ignorePathSegments[i])
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user