Ghost CMS email config
I’m running into an issue with Ghost CMS where users are unable to sign up for my newsletter due to an email configuration problem. Here’s the setup and what I’ve tried so far:
#### Steps Taken:
1. Created Subdomain in Mailgun:
- Subdomain:
Mailgun Logs: #### Question: - Is using environment variables in Railway instead of
mg.domain.com
2. DNS Configuration:
- Added MX, TXT, and CNAME records to my Namecheap registrar.
3. DNS Check & Verification:
- All records passed DNS checks and are verified in Mailgun.
4. Email Configuration in Railway:
- I added the email settings as Railway environment variables instead of using config.production.json
(I don’t believe I have access to the config file due to deployment via a Railway Docker image).
Environment Variables:
Reference:
https://ghost.org/docs/config/
5. Mailgun Configuration Verification:
- I used swaks
to confirm that my Mailgun SMTP settings are correct.
- A test email was successfully sent and received via my terminal.
Mailgun Logs: #### Question: - Is using environment variables in Railway instead of
config.production.json
a workable approach for Ghost CMS email configuration?
Any insights or suggestions would be greatly appreciated.Ghost - The Professional Publishing Platform
Configuration - Adapt your publication to suit your needs
Find out how to configure your Ghost publication or override Ghost's default behaviour with robust config options, including mail, storage, scheduling and more!
2 Replies
Project ID:
71b92ac0-afb1-4da1-af80-1cc0780f0330
71b92ac0-afb1-4da1-af80-1cc0780f0330
Further testing and logs:
I am able to send newsletters (bulk emails) from the Ghost CMS admin panel to myself, confirming that the bulk email functionality is working as expected.
However, I am unable to:
-- Use the "Forgot Password" functionality.
-- Sign up for the newsletter via the front-end form.
Summary of Error Messages for Ghost CMS Email Issues
1. Forgot Password
Issue:
When attempting to reset a password via the "Forgot Password" feature, the email fails to send, resulting in the following error message:
Frontend Error Message:
"Failed to send email. Reason: Can't send mail - all recipients were rejected: 550 5.7.1 Relaying denied."
Console Error:
POST https://domain.com/ghost/api/admin/authentication/password_reset/ 500 (Internal Server Error)
Railway Logs:
2. Sign Up for Newsletter
Issue:
When trying to sign up for a newsletter via the front-end form on Ghost CMS, the system fails to send the confirmation email, resulting in a 500 Internal Server Error.
Frontend Error Message:
"Failed to load resource: the server responded with a status of 500 () /members/api/send-magic-link/:1"
Railway Logs: