> ts=2024-09-15T17:58:49.480Z caller=coordinator.go:118 level=error component=configuration msg="Loadion file failed" file=/etc/alertmanager/alertmanager.yml err="yaml: unmarshal errors:\n line 7: field tls_config not found in type config.plain"
It's saying that you cannot put "tls_config" as a top-level key in Prometheus config. Since the config file is invalid, it cannot run.
As I said before, if you need to use tls_config then it has to be under the E-mail receiver.
require_tls: true
tls_config:
... blah
You don't need to repeat the smarthost / auth_username / auth_password / require_tls if you've set them globally.
But unfortunately you *do* need to put a separate "tls_config" section under every email receiver.
> tls_config:
> cert_file: /home/chinelo/alertmanager.crt
> key_file: /home/chinelo/alertmanager.key
That means you want to authenticate to your SMTP server using a TLS client certificate. I note that if I connect to it, it says it only supports password authentication (LOGIN and PLAIN):
...
ehlo wombat
250-mx.zohomail.com Hello wombat (x.x.x.x (x.x.x.x))
250-AUTH LOGIN PLAIN
250 SIZE 32505856
I believe the normal way to do TLS client authentication would be with the SASL "EXTERNAL" mechanism. But since you are already providing an auth_username and auth_password, I don't think you'll need to provide a TLS certificate as well. (In which case, maybe you don't need a tls_config section at all).
However, that's all detail around your particular SMTP server, and maybe it works in a weird way.