1. Installation
$ yum -y install http://dl.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm$ yum -y install git python-pip libvirt-python libxml2-python python-websockify supervisor nginx
======================================================================================================
2. Install python requirements and setup Django environment
$ git clone git://github.com/retspen/webvirtmgr.git$ cd webvirtmgr$ pip install -r requirements.txt # or python-pip (RedHat, Fedora, CentOS, OpenSuse)$ ./manage.py syncdb$ ./manage.py collectstatic
Adding additional superusers
$ ./manage.py createsuperuser
#这个是管理员账号,用上面的admin和这个管理员账号都可以登陆webvirtmgr的web界面管理平台
[root@localhost ~]# git clone git://github.com/retspen/webvirtmgr.git
Initialized empty Git repository in /root/webvirtmgr/.git/
remote: Counting objects: 5721, done.
remote: Total 5721 (delta 0), reused 0 (delta 0), pack-reused 5721
Receiving objects: 100% (5721/5721), 3.01 MiB | 467 KiB/s, done.
Resolving deltas: 100% (3683/3683), done.
[root@localhost ~]# cd webvirtmgr
[root@localhost webvirtmgr]# pip install -r requirements.txt # or python-pip (RedHat, Fedora, CentOS, OpenSuse)
/usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:90: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
InsecurePlatformWarning
You are using pip version 7.1.0, however version 8.1.2 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Collecting django==1.5.5 (from -r requirements.txt (line 1))
/usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:90: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
InsecurePlatformWarning
Downloading Django-1.5.5.tar.gz (8.1MB)
100% |████████████████████████████████| 8.1MB 62kB/s
Collecting gunicorn==18.0 (from -r requirements.txt (line 2))
Downloading gunicorn-18.0.tar.gz (366kB)
100% |████████████████████████████████| 368kB 390kB/s
Collecting lockfile>=0.9 (from -r requirements.txt (line 3))
Downloading lockfile-0.12.2-py2.py3-none-any.whl
Installing collected packages: django, gunicorn, lockfile
Running setup.py install for django
Running setup.py install for gunicorn
Successfully installed django-1.5.5 gunicorn-18.0 lockfile-0.12.2
[root@localhost webvirtmgr]# ./manage.py syncdb
WARNING:root:No local_settings file found.
Creating tables ...
Creating table auth_permission
Creating table auth_group_permissions
Creating table auth_group
Creating table auth_user_groups
Creating table auth_user_user_permissions
Creating table auth_user
Creating table django_content_type
Creating table django_session
Creating table django_site
Creating table servers_compute
Creating table instance_instance
Creating table create_flavor
You just installed Django's auth system, which means you don't have any superusers defined.
Would you like to create one now? (yes/no): yes
Username (leave blank to use 'root'): admin
Email address: liujianfei@uzai.com
Password:
Password (again):
Superuser created successfully.
Installing custom SQL ...
Installing indexes ...
Installed 6 object(s) from 1 fixture(s)
[root@localhost webvirtmgr]# ./manage.py collectstatic
WARNING:root:No