Prerequisite: Once the Python is installed.
Installing Virtualenvwrapper
[Root@xu flaskr]# pip Install Virtualenvwrapper
To add virtualenvwrapper.sh to the environment variable, mkvirtualenv will prompt for no command.
[Root@xu bin]# source/opt/python3.4/bin/virtualenvwrapper.sh
-
workonSwitch to Environment
-
deactivateUnregister the current environment
-
lsvirtualenvList all environments
-
Mkvirtualenv Creating an environment
-
rmvirtualenvDelete an environment
-
cpvirtualenvReplication environment
-
cdsitepackagesCD to the directory of the current environment site-packages
-
lssitepackagesList content in the current environment site-packages
-
setvirtualenvprojectBinding existing projects and environments
-
wipeenvClear all third-party packages in the environment
Note:
environments created with MKVIRTUALENV are installed by default into /root/.virtualenvs
CentOS6.7 Virtual Environment Virtualenvwrapper installation