
Sometime back we announce a new forum software for Crunchify readers and for our client. It’s now open for all developers and bloggers if they want to get instant answers for any query they may have. I personally very fond of high knowledge rich forum.
Please visit https://ask.crunchify.com to get started. You do have options to login using Facebook, Twitter, Github or Gmail ID.
As you know Discourse is very popular forum software among all latest tech companies, we thought of giving a try. Also, it’s open source.
Another must related read:
- How to configure Mailgun Email Server on your Discourser Forum correct way?
- How to install Discourse Forum on Linode VM in ~10 min?
Discourse forum
basic setup went perfectly fine. It was simple. I used Linode as our hosting service provider for our client. Linode comes with special Ubuntu 14.04 LTS image
which was straight forward.
Once you install and setup Discourse on Linode, it’s very important to have email service
setup correctly. To be honest, it took me long time
to figure out how to setup Google App’s SMTP relay correct way in setting file discourse.conf
.
In this tutorial we will go over detailed steps on how to setup email service correct way if you are google App users.
If you have any of below questions also then you are at right place.
- Troubleshooting email on a new
Discourse install
- How do I change my SMTP settings (Discourse Docker Install)
- Emails with local SMTP
- How to edit e-mail settings for Discourse?
- How To Install Discourse on
Ubuntu 14.04
- Can’t send mail with gmail SMTP server (in discourse)
- How to setup Google App SMTP relay service?
Step-1
Login to Google Admin Console
Step-2
- Go to Apps
- Google Apps
- Setting for Gmail
- Advance Settings
- Search with text
relay

Step-3
- Mouse hover and click on
configure
- Provide all details as you see in below image
- Select
Only addresses in my domains
- Click check box for
Only accept mail from the specified IP address
- Provide your
droplet/host IP address
- Click check box for
Required TLS encryption
- Select
- Click on
Save
button to save settings

Step-4
- Login to your host/droplet
- Open
discourse.conf
file - Add below settings for email service
NOTE
: keep username and passwordfield empty
DISCOURSE_DEVELOPER_EMAILS: 'contact@crunchify.com' ## TODO: The domain name this Discourse instance will respond to DISCOURSE_HOSTNAME: 'ask.crunchify.com' ## TODO: The mailserver this Discourse instance will use DISCOURSE_SMTP_ADDRESS: smtp-relay.gmail.com DISCOURSE_SMTP_PORT: 587 DISCOURSE_SMTP_USER_NAME: DISCOURSE_SMTP_PASSWORD: #DISCOURSE_SMTP_ENABLE_START_TLS: true
Step-5
Save your setting and initialize restart of your discourse
application. Your email service should be configured correct way now.
Once logged in to your server follow below steps:
$ cd /var/discourse $ vi containers/app.yml $ git pull $ ./launcher rebuild app
Enjoy and happy blogging.
This doesnt work
What error are you getting?
Hi, I just dont get emails working via GSuite.
Any help here?
I also started a topic here:
https://meta.discourse.org/t/gmail-smtp-relay-setup-not-working/123005
Hi Zacharias – we moved over to Mailgun for sending all emails.
Could you try this tutorial? https://crunchify.com/how-to-configure-mailgun-email-server-on-discourse-forum-correct-way/
Thank you, I’ll try this. Would be nice, if that stands on the top of this blog post…
Added details as part of another must read 🙂
Good point. I’ll make a link on the top of this page as 2nd option.
Hello!
Can i use it with Zoho or Yandex ?
I’m not sure about Yandex. But yeah for sure with Zoho. Try following their tutorials for more details.
How Many Emails Per day???
As per Google – it’s 10k per day. Here are some more details.
Thanks for this Setup Guide 🙂
you are welcome.
Hello, i have same configuration since 6 month on abuseat . org
because in mail header i have Received: from localhost.localdomain 🙁
you have the same problem:
X-Feedback-Id: 57a92c710e6fc42e8ff5b0e8:mailgun
Sender: noreply@ask.crunchify.com
X-Mailgun-Sid: WyJiZGI1MyIsICJob3RmaXJlbmV0QGdtYWlsLmNvbSIsICI3ZTQ0NCJd
Received: from localhost.localdomain (li976-213.members.linode.com [45.33.22.213])
Thanks
Hi Hotfirenet. We moved to mailgun few months back: https://crunchify.com/how-to-configure-mailgun-email-server-on-discourse-forum-correct-way/.
Are you still getting same header? Could you please share screenshot? I would like to debug more.
i have the same header result:
X-Feedback-Id: 57a92c710e6fc42e8ff5b0e8:mailgun
Sender: noreply@ask.crunchify.com
X-Mailgun-Sending-Ip: 209.61.151.224
X-Mailgun-Sid: WyJiZGI1MyIsICJob3RmaXJlbmV0QGdtYWlsLmNvbSIsICI3ZTQ0NCJd
Received: from localhost.localdomain (li976-213.members.linode.com [45.33.22.213])
by mxa.mailgun.org with ESMTP id 57c93c41.7f98440b2a70-in2;
Fri, 02 Sep 2016 08:45:53 -0000 (UTC)
Date: Fri, 02 Sep 2016 08:45:52 +0000
From: noreply@ask.crunchify.com
Reply-To: noreply@ask.crunchify.com
That’s right. I also noticed the same. I tried adding 3rd line below to /etc/hosts file but still i’m getting localhost in email.
I’ll dig more and update if I find solution.
Just going through hoops of learning about linux/nginx admin & discourse setup. Thanks for the guide. Why did you move to mailgun in the end, problems with smtp-relay.gmail.com? I had tried with authentication setup but not working so will try without as you suggest, but just wondering if I shouldn’t go for a dedicated smtp service provider instead. Thanks!
Hi Pete – there isn’t any problem setting up Discourse with Google SMTP-relay. Just because of daily email limitation I moved to mailgun. It seems a registered G Suite user can’t relay more than 10,000 messages in a 24-hour period.