I used Windows 10’s WSL2 to install Docker and deployed my own Discourse application.I modified the SMTP configuration items in discourse/config/discourse_defaults.conf, and re-ran d/boot_dev -p, d/rails s, and d/ember-cli, but the email still cannot be sent. I have no way of determining where the problem lies.Should I configure SMTP in discourse/config/discourse_defaults.conf? I used d/mailhog to test, but the bash just kept repeating “[APIv1] KEEPALIVE api/v1/events”.Is there a convenient and obvious way to verify the validity of my SMTP configuration?
AI-generated summary
A user, zhongziqi, is having trouble sending emails in a Discourse development environment set up via Docker on WSL2, despite configuring SMTP in discourse_defaults.conf and restarting services. They are unsure if SMTP should be configured in that file and are seeing repeated [APIv1] KEEPALIVE api/v1/events messages in the console. NateDhaliwal clarifies that in a development environment, SMTP credentials may not be needed and points to the default configuration. He also notes the keepalive message is normal and suggests accessing MailHog via port 8025 to view sent emails. tobiaseigen welcomes the user and asks if the issue is resolved, recommending closing the topic if so, or seeking further help if still stuck, suggesting a VPS setup might be easier for beginners.
IIRC if you are using a development environment, you don’t need to set up an SMTP username and password.
Also:
That seems normal, since I also see that in my development environment’s console when running mailhog.
You’ll have to open port (I think) 8025 to view the mailhog page. There, you can see the emails sent.
@zhongziqi welcome to our community!
Did @NateDhaliwal’s post answer your question? If so you can close this topic by ticking the solutions button on his post.
If not, let us know if you’re still feeling stuck! Some people find it easier at first to just follow the official install using a VPS rather than trying to start by setting up a dev install on their local machine.