I installed ghost on a droplet on Digital Ocean. I install it directly from the marketplace. I bought a custom domain from Namecheap and also an email. I got the domain working. But when I setup my email. The email is being sent from noreply@atharv’.‘vadehra’.‘me according to error logs. I want it to be sent from atharv@vadehra’.'me.
“Error: Can’t send mail - all recipients were rejected: 553 5.7.1 <noreply@vadehra’.‘me>: Sender address rejected: not owned by user atharv@vadehra’.'me\n at createMailError (/var/www/ghost/versions/5.47.1/core/server/services/mail/GhostMailer.js:68:12)\n at SMTPConnection._formatError (/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:790:19)\n at SMTPConnection._actionRCPT (/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:1632:28)\n at SMTPConnection. (/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:1585:30)\n at SMTPConnection._processResponse (/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:953:20)\n at SMTPConnection._onData (/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:755:14)\n at TLSSocket.SMTPConnection._onSocketData (/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:193:44)\n at TLSSocket.emit (node:events:513:28)\n at addChunk (node:internal/streams/readable:315:12)\n at readableAddChunk (node:internal/streams/readable:289:9)\n at TLSSocket.Readable.push (node:internal/streams/readable:228:10)\n at TLSWrap.onStreamRead (node:internal/stream_base_commons:190:23)”,“hideStack”:false},“msg”:“Failed to send email. Reason: Can’t send mail - all recipients were rejected: 553 5.7.1 <noreply@vadehra’.'me>: Sender address rejected: not owned by user atharv@vadehra.me.”,“time”:“2023-05-20T18:09:37.811Z”,“v”:0}
As you can see, you put the from property into the options. However, this should be one level up, putting it on the same level as transport. Have a look at the documentation here for more context.
I still got the same log error as before. Try and signup on atharv.vadehra.me and then inspect the page. I have tried multiple things, couldn’t find any solution.
Did you restart Ghost after making the config changes?
Also, <noreply@vadehra.me>: Sender address rejected: not owned by user atharv@vadehra.me suggests that the server is rejecting the sender. Have you created an alias for noreply@vadehra.me?
Yes, I restarted ghost.
Can’t I send my emails from atharv@vadehra.me. I not how do you suggest me to create an alias. I tried looking through www.privateemail.com.
This is my config file. Now the error is that the mail are sent from noreply@atharv. vadehra".“me. I bought a domain from namecheap which is vadehra”."me. I have tried everything changing the from attribute but nothing is working. I create an Alias noreply@vadehra.me
Config given by @jannis is also not working. Still the sending address is noreply@atharv.vadehra.me. I tried changing the location of the from attribute. Still It is not working.
That is surprising, since this is the only place within Ghost where the from-email for transactional emails is set.
The noreply-email is used by Ghost if no configuration is found and is basically a fallback.
I have a strong feeling that there is still something wrong with the configuration file. Can you send us the entire file again, with the from property on the correct level? I’ll try and run it on my local machine then to test it and eliminate any errors.
{"name":"Log","hostname":"ghostonubuntu2204-s-1vcpu-1gb-blr1-
01","pid":211762,"level":50,"version":"5.47.1","err":{"id":"440e9970-fadc-11ed-9f77-
ad3b785d7a29","domain":"https://atharv.vadehra.me","code":"EENVELOPE","name":"EmailError","st
atusCode":500,"level":"normal","message":"Failed to send email. Reason: Can't send mail - all
recipients were rejected: 553 5.7.1 <noreply@atharv.vadehra.me>: Sender address rejected: not
owned by user atharv@vadehra.me.","help":"\"Please see https://ghost.org/docs/config/#mail for
instructions on configuring email.\"","stack":"Error: Can't send mail - all recipients were rejected: 553
5.7.1 <noreply@atharv.vadehra.me>: Sender address rejected: not owned by user
atharv@vadehra.me\n at createMailError
(/var/www/ghost/versions/5.47.1/core/server/services/mail/GhostMailer.js:68:12)\n at
SMTPConnection._formatError (/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-
connection/index.js:790:19)\n at SMTPConnection._actionRCPT
(/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:1632:28)\n
at SMTPConnection.<anonymous>
(/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:1585:30)\n
at SMTPConnection._processResponse
(/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:953:20)\n
at SMTPConnection._onData (/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp
-connection/index.js:755:14)\n at TLSSocket.SMTPConnection._onSocketData
(/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:193:44)\n
at TLSSocket.emit (node:events:513:28)\n at addChunk
(node:internal/streams/readable:315:12)\n at readableAddChunk
(node:internal/streams/readable:289:9)\n at TLSSocket.Readable.push
(node:internal/streams/readable:228:10)\n at TLSWrap.onStreamRead
(node:internal/stream_base_commons:190:23)","hideStack":false},"msg":"Failed to send email.
Reason: Can't send mail - all recipients were rejected: 553 5.7.1 <noreply@atharv.vadehra.me>:
Sender address rejected: not owned by user atharv@vadehra.me.","time":"2023-05-
25T09:12:25.995Z","v":0}
{"name":"Log","hostname":"ghostonubuntu2204-s-1vcpu-1gb-blr1-
01","pid":211762,"level":50,"version":"5.47.1","err":{"id":"440e9970-fadc-11ed-9f77-
ad3b785d7a29","domain":"https://atharv.vadehra.me","code":"EENVELOPE","name":"EmailError","st
atusCode":500,"level":"normal","message":"Failed to send email. Reason: Can't send mail - all
recipients were rejected: 553 5.7.1 <noreply@atharv.vadehra.me>: Sender address rejected: not
owned by user atharv@vadehra.me.","help":"\"Please see https://ghost.org/docs/config/#mail for
instructions on configuring email.\"","stack":"Error: Can't send mail - all recipients were rejected: 553
5.7.1 <noreply@atharv.vadehra.me>: Sender address rejected: not owned by user
atharv@vadehra.me\n at createMailError
(/var/www/ghost/versions/5.47.1/core/server/services/mail/GhostMailer.js:68:12)\n at
SMTPConnection._formatError (/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-
connection/index.js:790:19)\n at SMTPConnection._actionRCPT
(/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:1632:28)\n
at SMTPConnection.<anonymous>
(/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:1585:30)\n
at SMTPConnection._processResponse
(/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:953:20)\n
at SMTPConnection._onData (/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp
-connection/index.js:755:14)\n at TLSSocket.SMTPConnection._onSocketData
(/var/www/ghost/versions/5.47.1/node_modules/nodemailer/lib/smtp-connection/index.js:193:44)\n
at TLSSocket.emit (node:events:513:28)\n at addChunk
(node:internal/streams/readable:315:12)\n at readableAddChunk
(node:internal/streams/readable:289:9)\n at TLSSocket.Readable.push
(node:internal/streams/readable:228:10)\n at TLSWrap.onStreamRead
(node:internal/stream_base_commons:190:23)","hideStack":false},"msg":"Failed to send email.
Reason: Can't send mail - all recipients were rejected: 553 5.7.1 <noreply@atharv.vadehra.me>:
Sender address rejected: not owned by user atharv@vadehra.me.","time":"2023-05-
25T09:12:25.995Z","v":0}