You are not logged in.
Hi,
I recently installed on my computer the SSMTP package (SSMTP wiki guide). Seems to be working fine. I restarted my computer a few days later and one of my cronjob (a PHP script) started to send emails to say I have a warning inside the script.
The problem is the email is sent to the wrong person. It takes my username and appends @gmail.com. The problem I want to change it to my email address (username@gmail.com exists and it's not me).
How could I change that ?
Last edited by K-Jtan (2015-04-28 18:23:36)
Offline
By defining aliases. The wiki includes an example.
Edit: actually I'm not sure whether that works for "To:" as well...
Last edited by Raynman (2015-04-28 17:54:16)
Offline
By defining aliases. The wiki includes an example.
These are my two alias in my /etc/ssmtp/revaliases
Note my_username = firstname
root:firstname.lastname@gmail.com:smtp.gmail.com:587
my_username:firstname.lastname@gmail.com:smtp.gmail.com:587
the emails are still forward to firstname@gmail.com
Last edited by K-Jtan (2015-04-28 17:55:31)
Offline
Yes, hence my edit. I read your post too quickly (and it's the first time I see a question about the "To" side).
Do you have
Root=firstname@gmail.com
in ssmtp.conf? Or no "Root" setting at all (although I wouldn't expect it to add @gmail.com in that case)?
Because it says
# The user that gets all the mails (UID < 1000, usually the admin)
Last edited by Raynman (2015-04-28 18:04:30)
Offline
Yes, hence my edit. I read your post too quickly (and it's the first time I see a question about the "To" side).
Do you have
Root=firstname@gmail.com
in ssmtp.conf? Or no "Root" setting at all (although I wouldn't expect it to add @gmail.com in that case)?
I just checked and I have
root = postmaster
Last edited by K-Jtan (2015-04-28 18:07:01)
Offline
Fixed I change postmaster for firsname.lastname.
Tested and works.
Thank you for the hints Raynman
Offline