Mail Alert Contact Point

Hello, I am having trouble setting up the mail notification in Grafana. I am not quite fit in the topic yet, please excuse that.
I have installed grafana, prometheus according to the following instructions:

I am now trying to test the mail notifications, but always get an error that the grafana.ini needs to be edited. I have entered the following for smtp:
[smtp]
enabled = true
host = MAILSERVER.SERVERHOST:25
user = testing@MYDOMAIN.eu
#If the password contains # or ; you have to wrap it with triple quotes. Ex ā€œā€ā€œ#password;ā€ā€œā€
password = Testing123!
;cert_file =
;key_file =
skip_verify = true
from_address = testing@MYDOMAIN.eu
from_name = Gandalf Grafana
#EHLO identity in SMTP dialog (defaults to instance_name)
;ehlo_identity = dashboard.example.com
#SMTP startTLS policy (defaults to ā€˜OpportunisticStartTLSā€™)
;startTLS_policy = NoStartTLS
But unfortunately this does not work, can you help me?

I can also find the grafana.ini inside the container, how can I edit it?

Welcome

Did you restart the grafana service? A change in the ini file requires a restart

Yes, iĀ“ve restarted the Container.
I just found a grafana.ini file inside the container under /etc/grafana/, but I am unsure how to include it under volumes so I can edit it.

It should be found under conf folder

Oh and you are using an unofficial docker image. U should probably reach out to that repo owner

Ok, I will redeploy grafana and try again. The alert function would be very important to me, is the alert manager absolutely necessary for this? But maybe this is the wrong forum for this question.
Sorry for my bad language and naivety. But Iā€™m trying to learn the ropes.

1 Like

if i understand right,
you have to store this file in diffĆØrent the persistent volume,
i think this link can help you :
https://localhost:3000/t/change-grafana-ini-in-docker-install/27605/6

Thanks for your help. Now, iĀ“ve edited the envirement Settings with the SMTP data, and now i get Mails.
But unfortunately the links inside the message route to ā€œlocalhostā€, i would like to link this to an ip address. in grafana.ini i changed the domain=IPADDRESS, but that didnā€™t work, still localhost. Is there another place to change the address?

iā€™m not expert in docker but i think this is about network settings in your docker compose file
this link may help you :
https://stackoverflow.com/questions/49913355/domain-configuration-in-docker-compose