HostOnNet Blog

Installing Python 2.7 on CentOS for Django Framework

Looking for Linux Server Admin or WordPress Expert? We can help.

Django Framework need python 2.7 to run. CentOS come with python 2.6.

To install python 2.7, run

wget -qO- http://people.redhat.com/bkabrda/scl_python27.repo >> /etc/yum.repos.d/scl.repo
yum install python27

Now enable python 2.7 by running

scl enable python27 bash

python –version

[root@lin ~]# python --version
Python 2.7.5
[root@lin ~]#

Installing Setuptool, pip and Django

cd /usr/local/src
wget https://pypi.python.org/packages/source/s/setuptools/setuptools-2.1.tar.gz --no-check-certificate
cd /usr/local/src/setuptools-2.1
python ez_setup.py
easy_install pip
pip install -U django==1.5.4

Posted in Python. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.