【报错】="one or more config change subscribers failed to apply new config" file=/etc/alertmanager/config/alertmanager.yaml err="failed to parse templates: template: email.tmpl:3: unexpected \",\" in range"
[root@k8s-master-01 alertmanager]# kubectl logs -n monitoring alertmanager-main-0 -c alertmanager
level=info ts=2022-11-29T15:23:26.232Z caller=main.go:216 msg="Starting Alertmanager" version="(version=0.21.0, branch=HEAD, revision=4c6c03ebfe21009c546e4d1e9b92c371d67c021d)"
level=info ts=2022-11-29T15:23:26.232Z caller=main.go:217 build_context="(go=go1.14.4, user=root@dee35927357f, date=20200617-08:54:02)"
level=info ts=2022-11-29T15:23:26.309Z caller=coordinator.go:119 component=configuration msg="Loading configuration file" file=/etc/alertmanager/config/alertmanager.yaml
level=info ts=2022-11-29T15:23:26.310Z caller=coordinator.go:131 component=configuration msg="Completed loading of configuration file" file=/etc/alertmanager/config/alertmanager.yaml
ts=2022-11-29T15:23:26.318Z caller=coordinator.go:137 component=configuration msg="one or more config change subscribers failed to apply new config" file=/etc/alertmanager/config/alertmanager.yaml err="failed to parse templates: template: email.tmpl:3: unexpected \",\" in range"
【原因】说明文件email.tmpl第三行存在语法错误,修改更正重新生成secret解决