RU EN ES FR CN

Domain and IP whois

Domains HostingHosting VPS HostingVPS / VDS SSLCertificates Company Company

VPS / VDS hosting >  Installing Django on VPS

Installing Django on a virtual server is done using a package that includes all the necessary services. Installation is performed in ssh linux console, Centos 7 is used as a server. The latest version of the package can be found on the developer's website Bitnami

Before starting the installation, you need to make sure that there are no pre-installed services on the server, for example, to remove apache, use the command:


# yum remove httpd 


We also recommend to immediately configure the firewall service:


# iptables -A INPUT -p tcp -m tcp --dport 80 -j ACCEPT

# iptables -A INPUT -p tcp -m state --state NEW -m tcp --dport 80 -j ACCEPT

# service iptables save

# service iptables restart


Download and install the package:


# wget http://iso.ripnet.ru/vm-apps/bitnami-django-3.1.6-0-linux-x64-installer.run

# chmod +x bitnami-django-3.1.6-0-linux-x64-installer.run

# ./bitnami-django-3.1.6-0-linux-x64-installer.run


The script will offer a choice to install additional tools:

SQLite [Y/n] : Y

Select by default (Y)

MySQL [Y/n] : Y

Select by default (Y)

PostgreSQL [Y/n] : Y

Select by default (Y)

Django : Y (Cannot be edited)

Node.js [Y/n] : Y

Select by default (Y)

Is the selection above correct? [Y/n]: Y

The choice was made correctly.

Select a folder [/opt/djangostack-3.1.6-0]: 

Press Enter if you want to leave the specified path as default

MySQL Server root password :

Re-enter password :

You need to set a password for the database root user

Please enter your database 'postgres' user password.

PostgreSQL postgres user password :

Re-enter password :

A password must be set for the postgres database user

Do you want to setup an initial project? [Y/n]: Y

Let's create a test project (recommended for beginners)

Project Name [Project]: Test

Specify the name of the project without spaces

[1] SQLite: The project will be configured to use SQLite as the database. Suitable for development and test environments.

[2] MySQL: The project will be configured to use MySQL as its database. Recommended for production environments.

[3] PostgreSQL: The project will be configured to use PostgreSQL as a database. Recommended for production environments.

Please choose an option [1] : 2

We'll choose MySQL due to its popularity.

Hostname [xx.xxx.xxx.xx]: 

We will indicate the name of our domain if available or leave it as it is.
 
Do you want to continue? [Y/n]: Y
 
Proceed with installation.
 
Launch Django application. [Y/n]: Y
 
Launch the application.
 
Now you can open a link like http://server_ip/ in a browser and check the application.   


To add a new project, use the command


# cd /opt/djangostack-3.1.6-0/apps/django/django_projects/PROJECT

# django-admin.py startproject PROJECT


Django installation complete.

Client Area

Log in

Forgot Password


Sign Up


Check mail:

Mail:
Pass.:

VPS Application catalog

Knowledge base

Additional services

VPS hosting

We were chosen by leading media companies with large volumes of data and high load

Calculate tariff

Domain transfer