Smtp outbound configuration

Hi

I want to setup alerting using gmail as my outbound smtp server, gmail requires you to use ssl / tls and provide a gmail account and password.

where do I config this ?

if I enter this

config:
host: smtp.gmail.com
port: 465
secure: true
secrets:
user:
password:

into kibana.yaml and restart the service, the service keeps crashing until I remove it

what am I doing wrong ?