To deploy as root, Python feeds can also use http://mirrors.aliyun.com/pypi/simple/
Modifying the System
Change the SELinux configuration file/etc/selinux/config,selinux=disabled
Ssh-keygen
~/.ssh/authorized_keys Write Id_rsa.pub
Install Python 2.7.9
Yum-y Update
wget https://www.python.org/ftp/python/2.7.9/Python-2.7.9.tgz
Tar zxvf python-2.7.9.tgz
./configure
Make install
Install PIP
wget https://bootstrap.pypa.io/ez_setup.py
Python ez_setup.py
Easy_install-i http://pypi.douban.com/simple Pip
Configuring the default PIP source
Vim ~/.pip/pip.conf
[Global]
Index-url = Http://pypi.douban.com/simple
Trusted-host = pypi.douban.com
Set up a virtual directory
#pip Install requests[security]
Pip Install Virtualenv
Virtualenv. env
source. env/bin/activate
Deployment Code
git clone horizon.git
Install the Python packages required by horizon
Yum-y Install Python-devel
Yum-y Install Libffi-devel
Pip Install–r requirements.txt
Test Horizon Launch
CD Horizon
./manage.py Runserver
CentOS 6.5 Department Horizon