Atlantic.Net Blog

How to Install Discourse Forum on Debian 10 with Nginx and Let’s Encrypt

Discourse is open-source forum software written in Ember.js and Ruby on Rails. You can build your own online discussion forums and chat rooms using Discourse. Discourse is mostly used by gamers to create content accessible by the community. It is used by many companies including New Relic, Cloudflare, and Docker to power their communities. Discourse offers a rich set of features including dynamic notifications, infinite scrolling, powerful moderation, spam blocking, two-factor authentication, a comprehensive API, and many more.

In this post, we will explain how to install Discourse Forum with Docker on Debian 10.


  • A fresh Debian 10 server on the Atlantic.Net Cloud Platform
  • A valid domain name pointed at your server
  • A root password configured on your server

Step 1 – Create Atlantic.Net Cloud Server

First, log in to your Atlantic.Net Cloud Server. Create a new server, choosing Debian 10 as the operating system with at least 2GB RAM. Connect to your Cloud Server via SSH and log in using the credentials highlighted at the top of the page.

Once you are logged in to your Debian 10 server, run the following command to update your base system with the latest available packages.

apt-get update -y

Step 2 – Install Docker

By default, the latest version of Docker is not available in the Debian default repository, so you will need to add the Docker official repository to your system.

First, install the required dependencies using the following command:

apt-get install git apt-transport-https ca-certificates curl gnupg2 software-properties-common -y

Once all the dependencies are installed, add the Docker CE repository with the following command:

curl -fsSL$(. /etc/os-release; echo "$ID")/gpg | apt-key add -
add-apt-repository "deb [arch=amd64]$(. /etc/os-release; echo "$ID") $(lsb_release -cs) stable"

Once the repository is added, update the repository and install Docker CE with the following command:

apt-get update -y
apt-get install docker-ce -y

Once Docker CE is installed, you can proceed to install Discourse.

Step 3 – Install Discourse

First, create a directory for Discourse and download the latest version of Discourse with the following command:

mkdir /var/discourse
git clone /var/discourse

Next, change the directory to discourse and start the Discourse installation using the following command:

cd /var/discourse

During the installation, you will be asked to provide the Hostname, email, and SMTP details as shown below:

Hostname for your Discourse? []:

Checking your domain name . . .
Connection to succeeded.
Email address for admin account(s)? [[email protected],[email protected]]: [email protected]
SMTP server address? []:
SMTP port? [587]: 
SMTP user name? [[email protected]]: [email protected]
SMTP password? [pa$$word]: Jethva@1981
notification email address? [[email protected]]: [email protected]
Optional email address for Let's Encrypt warnings? (ENTER to skip) [[email protected]]: [email protected]
Optional Maxmind License key (ENTER to continue without MAXMIND GeoLite2 geolocation database) [1234567890123456]: 

Provide all the details and hit Enter. You should see the following output:

Does this look right?

Hostname          :
Email             : [email protected]
SMTP address      :
SMTP port         : 587
SMTP username     : [email protected]
SMTP password     : Jethva@1981
Notification email: [email protected]
Let's Encrypt : [email protected]
Maxmind license: (unset)

ENTER to continue, 'n' to try again, Ctrl+C to exit: 

Confirm all the information and hit Enter to start the installation. Once the installation has been finished, you should get the following output:

+ /usr/bin/docker run --shm-size=512m -d --restart=always -e LANG=en_US.UTF-8 -e RAILS_ENV=production -e UNICORN_WORKERS=4 -e UNICORN_SIDEKIQS=1 -e RUBY_GLOBAL_METHOD_CACHE_SIZE=131072 -e RUBY_GC_HEAP_GROWTH_MAX_SLOTS=40000 -e RUBY_GC_HEAP_INIT_SLOTS=400000 -e RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR=1.5 -e DISCOURSE_DB_SOCKET=/var/run/postgresql -e DISCOURSE_DB_HOST= -e DISCOURSE_DB_PORT= -e LETSENCRYPT_DIR=/shared/letsencrypt -e LC_ALL=en_US.UTF-8 -e LANGUAGE=en_US.UTF-8 -e -e [email protected] -e -e DISCOURSE_SMTP_PORT=587 -e [email protected] -e DISCOURSE_SMTP_PASSWORD=Jethva@1981 -e -e [email protected] -e [email protected] -h debian10-app -e DOCKER_HOST_IP= --name app -t -p 80:80 -p 443:443 -v /var/discourse/shared/standalone:/shared -v /var/discourse/shared/standalone/log/var-log:/var/log --mac-address 02:95:89:04:2c:d3 local_discourse/app /sbin/boot

Step 4 – Access Discourse

Now, open your web browser and access the Discourse web interface using the URL You should see the following page:

Click on the Register button. You should see the following page:

Provide your email address, username, and password, and click on the Register button. You should see the following page:

You will get an activation email in your mailbox. You can activate your Discourse account by clicking on the activation email.


In the above post, you learned how to install Discourse Forum with Docker on Debian 10. You can implement a Discourse Forum for your organization on your VPS hosting account from Atlantic.Net.


Get started with 12 months of free cloud VPS hosting

Free Tier includes:
G3.2GB Cloud VPS Server Free to Use for One Year
50 GB of Block Storage Free to Use for One Year
50 GB of Snapshots Free to Use for One Year