How To Install Askbot on CentOS 7

Install Askbot on CentOS 7

In this tutorial, we will show you how to install Askbot on your CentOS 7 server. For those of you who didn’t know, Askbot is a question and answer web forum and it looks like StackOverflow Q&A web forums. It is based on the Django web framework and written in Python programming language. It is an open-source Q&A web forum project maintained and developed by Evgeny Fadeev. Some most popular open-source projects like Ask-Fedora and Ask-LibreOffice uses the AskBot to provide support for their users and clients.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation Askbot on a CentOS 7 server.

Install Askbot on CentOS 7

Step 1. First, let’s start by ensuring your system is up-to-date.

Step 2. Installing Dependencies Askbot.

Install the required packages:

Step 3. Installing PostgreSQL.

Askbot uses PostgreSQL as a database system to store its data, so install it executing the following command:

Start Postgres and enable it to launch automatically at the boot time:

Step 4. Create Database For Askbot.

First of all, we will create a database tech brown for AskBot project:

The next step is to edit the Postgres configuration for authentication setup, which you can do by heading to the ‘pgsql/data’ directory and editing the ‘pg_hba.conf’ file with nano:

Once inside the file, change all authentication to md5, as shown below:

Save, close the file and restart PostgreSQL:

Step 5. Installing Askbot.

We will install Askbot under a user named ‘askbot’, and using the virtualenv python. So let’s begin:

Next, add this new user to the wheel group:

Upgrade pip to the latest version:

Next, install the virtualenv package:

Log in as the askbot user previously created, and create a new virtual environment with virtualenv:

Activate this new virtual environment, by executing the following command:

Next, install Askbot and other required packages with pip:

Next, create a new directory for the ‘Askbot’ project. Please make sure you don’t use ‘askbot’ as the directory name:

Initialize a new Askbot project by executing the following commands:

So Askbot is now installed on the ‘testing directory. Now we need to generate Askbot Django static files and the database. Run the command below to generate Askbot Django static files:

Generate the database:

So, Askbot has been installed and the testing project configured. Test it with run server:

With a web browser, go to the server IP address, and you should see a forum page.

Install Askbot on CentOS 7

Congratulations! You have successfully installed Askbot. Thanks for using this tutorial for installing Askbot on your CentOS 7 system. For additional help or useful information, we recommend you to check the official Askbot website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!