NethServer and Discourse forum

Hi all,

I am looking at installing Discourse forum on my LOCAL development virtual machine.

All is working correctly…

… except:

  • Discourse display the above registration page and I have to “register a new account to get started”.
    I click Register.
  • The " Register Admin Account" page is displayed.
    My email address titi@toto.com I entered when I installed Discourse is automatically displayed.
    I enter a user name and password. I click Register.
  • The " Confirm your Email" page is displayed saying “We sent an activation mail to titi@toto.com . Please follow the instructions in the email to activate your account.

I receive no email.

At the console of the LOCAL Discourse server, I can send manually an email to titi@toto.com without problem and he receives it.

The configuration for the email In the app.yml file of Discourse:

  ...
  ## TODO: The SMTP mail server used to validate new accounts and send notifications
  # SMTP ADDRESS, username, and password are required
  # WARNING the char '#' in SMTP password can cause problems!
  DISCOURSE_SMTP_ADDRESS: mail.toto.com
  DISCOURSE_SMTP_PORT: 587
  DISCOURSE_SMTP_USER_NAME: michelandre@toto.com
  DISCOURSE_SMTP_PASSWORD: "michelandre-password"
  ...

The NethServer running toto.com is directly connected to the Internet
The user michelandre is in the admin group at toto.com.
All the CNAME at the domain registrar are all entered and working correctly.

If I run: /var/discourse/discourse-doctor

...
==================== MAIL TEST ====================
For a robust test, get an address from http://www.mail-tester.com/
Sending mail to REDACTED  . . 
Testing sending to titi@toto.com using michelandre@toto.com:michelandre-password@mail.toto.com:587.
======================================== ERROR ========================================
Connection to port 587 failed.
====================================== SOLUTION =======================================
The most likely problem is that your server has outgoing SMTP traffic blocked.
If you are using a service like Mailgun or Sendgrid, try using port 2525.
=======================================================================================
...

QUESTIONS:

Any suggestion appreciated,

Michel-André

1 Like

I think you need to use a real domain name that a dns provider will point to your nethserver, with the login and passwd of a real user on that nethserver

Then you can check in maillog if the email has been recepted from discourse and if it has been directed either to another smtp or moved ton an internal mailbox

Only log can help