Email Alert Notification: FROM address does not work

11 views
Skip to first unread message

Steve

unread,
May 21, 2020, 5:31:00 PM5/21/20
to Prometheus Users
Hi
Email alert notification is working well with one exception: the FROM address.
I am currently sending the email TO my gmail address.
I have configured the FROM email address (different from the TO address) but it does not work.
In the email notification I received, the FROM email address is always equal to the TO email address (as if I send the email).
Is this a bug with alertmanager or is it gmail that works this way?

Thank you for your help!

-Steve

Julien Pivotto

unread,
May 21, 2020, 5:35:19 PM5/21/20
to Steve, Prometheus Users
Can you share your configuration (just alter the emails)?

>
> --
> You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-use...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/11c03234-cecf-443d-b86b-753220ee8e47%40googlegroups.com.


--
Julien Pivotto
@roidelapluie

Steve

unread,
May 21, 2020, 8:18:46 PM5/21/20
to Steve, Prometheus Users
Hi Julien
Here goes:

    receivers:
    - name: email
      email_configs:
      - to: my-e...@gmail.com
        from: alertm...@org.com
        smarthost: smtp.gmail.com:587
        auth_username: my-e...@gmail.com
        auth_identity: my-e...@gmail.com
        auth_password: abcdefghijklmn
        send_resolved: true

-Steve

Brian Candler

unread,
May 22, 2020, 1:56:53 AM5/22/20
to Prometheus Users
The issue is that Gmail is forcing your From: address to be the same as your authenticated identity (to avoid spoofing).

You can add extra verified E-mail addresses to your Gmail account, and then you will be able to send using those as well.  It's in Gmail settings somewhere.

Beware that if the domain "org.com" is using SPF, then its SPF record in the DNS needs to allow outbound mail from Google's servers.  If org.com is already Google hosted that's fine - but then you'd be better logging into Google with an org.com GSuite account.

Steve

unread,
May 22, 2020, 10:28:23 AM5/22/20
to Brian Candler, Prometheus Users
Hi Brian
Thanks for the suggestion.
I looked for Gmail setting for adding a verified address.
No luck on my side.

-Steve

--
You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-use...@googlegroups.com.

Brian Candler

unread,
May 22, 2020, 12:34:33 PM5/22/20
to Prometheus Users
Reply all
Reply to author
Forward
0 new messages