Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Matomo is adding my site subdomain to my email #14038

Closed
davidtessier opened this issue Jan 28, 2019 · 5 comments
Closed

Matomo is adding my site subdomain to my email #14038

davidtessier opened this issue Jan 28, 2019 · 5 comments
Labels
answered For when a question was asked and we referred to forum or answered it.

Comments

@davidtessier
Copy link

I have an email address (noreply@whatever.com).
My Matomo installation is set to analytics.whatever.com

When I try to send automated reports, Matomo doesn't use the email address as defined in the settings, it is adding my sub domain and in turn it is failing and I get the error message:

An error occurred while sending 'HTML Email Report - 8.today.5.en - lpnxtyZpMNAIdViRHKaBRduonRwcQTDLfi_9X_YO.html' to email@hotmail.com. Error was 'Relaying disallowed as noreply@analytics.whatever.com'

As you can see, in the above error message, the email it is trying to use does is not the right email. It adds the sub domain. In Matomo General Settings -> Email I do not have it set like this.

How can I change this so that email reports will work from an address that doesn't include the subdomain?

@fdellwing
Copy link
Contributor

fdellwing commented Jan 28, 2019

What does you config says about noreply_email_address (and login_password_recovery_email_address/login_password_recovery_replyto_email_address)?

@davidtessier
Copy link
Author

davidtessier commented Jan 28, 2019

What does you config says about noreply_email_address (and login_password_recovery_email_address/login_password_recovery_replyto_email_address)?

UPDATE:
The config/config.ini.php did not have noreply_email_address or the other two addresses.

The congif/global.ini.php file had noreply_email_address = "noreply@{DOMAIN}"

I've added noreply_email_address = "noreply@mydomain.com" as a static value to the config/config.ini.php

This is what my config/config.ini.php looks like now, and I still get the error originally mentioned and it quotes an email address of noreply@sub.mydomain.com , even after a webserver reboot and a browser cache clear.

[mail]
transport = "smtp"
port = 465
host = "smtp.mydomain.com"
type = "Login"
username = "noreply@mydomain.com"
password = "#################"
encryption = "ssl"
noreply_email_address = "noreply@mydomain.com"
noreply_email_name = "DJT Analytics"
emails_enabled = 1
feedback_email_address = "support@mydomain.com

If I update the congif/global.ini.php file (I know it says not to) and replace the {DOMAIN} part of the code with my hard coded domain, it works. But I'd rather the config.ini.php work like it is supposed to. Am I putting the noreply_email_address in the wrong place? Does it have to be in a specific sequence in the file?

@tsteur
Copy link
Member

tsteur commented Jan 28, 2019

I recommend you configure a different email address for noreply_email_address. Or do you have it set already?

@fdellwing
Copy link
Contributor

Does it have to be in a specific sequence in the file?

Pretty sure it has to be in the General section?

@davidtessier
Copy link
Author

Does it have to be in a specific sequence in the file?

Pretty sure it has to be in the General section?

Moving the code to the general section worked. I have reverted the global.ini.php file, and done a test, and emails are sending.

Thank you to all who helped me sort this out. I really appreciate it!

@Findus23 Findus23 added the answered For when a question was asked and we referred to forum or answered it. label Jan 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
answered For when a question was asked and we referred to forum or answered it.
Projects
None yet
Development

No branches or pull requests

4 participants