
In this tutorial we are going to explain step-by-step instructions on How to install Discourse on Ubuntu 20.04 Also, we will provide you with some useful information about its usage.
Discourse is an open-source platform used for discussions forum, chat rooms, or as a mailing list management software. It is written in Ruby on Rails as a backend language, Ember.js as a frontend, and uses PostgreSQL for data storage. It offers many features such as 2FA (Two-factor authentication), Spam blocking, Comprehensive API, Social Login and etc. Installing Discourse can be done manually with a couple of steps or in an isolated environment with Docker.
In this blog post, we will use docker as an easier and faster solution and the estimated time for the installation should be a few minutes, depending on your network speed. Let’s get started!
Table of Contents
Prerequisites
Before we start with the installation there are a few requirements that need to be fulfilled:
- A VPS with at least 2GB of RAM (Our SSD 2 VPS plan)
- Fresh install of Ubuntu 20.04
- User privileges: root or non-root user with sudo privileges
- Pointed A record of domain or subdomain to your server IP address
- SMTP mail server. May use some external mail services like Mailgun, Sendgrid, Gmail, Hotmail and etc, if you do not have one
Step 1. Update the System
Fresh installation of Ubuntu 20.04 requires the latest software updates. Execute the following command to update the system to its latest version:
Step 2. Install Docker Container
As we mentioned before we will install Discourse in an isolated docker environment. Docker by default is available in Ubuntu 20.04 and we just need to execute the following commands to install it:
Once, the installation is complete start the docker service:
After starting the service, you need to enable it with the following command:
To check that the service is up and running, in the terminal execute the command below:
You should see the following output:
Step 3. Download and Install Discourse
Before we download the installation file for Discourse we will make a separate director for it:
Clone the discourse with the command bellow:
Go into the newly created directory and execute the command for installing Discourse
After executing the command for discourse setup, there will be a couple of inputs that need to be entered such as hostname, email address for admin account, SMTP server, SMTP username, SMTP password and email address for Let’s Encrypt as shown below:
Once you enter these values, there will be another window to check them again.
Hit “Enter” to approve them and allow some time for the installation to complete.
Once the installation is completed you can check that the docker container is running properly:
You should see the following output:
Step 4. Access The Web Interface
Access the discourse in the browser: https://discourse.yourdomain.com
Now, you need to click on the “Register” button and another form will open for Email, Username and Password.
The final step is to check your mailbox to confirm your administrator account creation.
Congratulations! You successfully installed Discourse on Ubuntu 20.04.
Of course, you don’t have to install Discourse on Ubuntu 20.04. If you find it difficult, you can simply ask our expert Linux admins to install Discourse on Ubuntu 20.04 for you. They are available 24×7 and will take care of your request immediately.
If you liked this post on how to install Discourse on Ubuntu 20.04, please share it with your friends on the social networks using the buttons on the left or simply leave a reply below. If you’re interested, check out our Discourse VPS plans. Thanks.