Setting up a Python Virtual Environment

Virtual environments are primarily useful for moments when you need to reconfigure or install software but need to be mindful of the influence on other programs and settings.

  1. Install the virtual environment: sudo apt-get install virtualenv or sudo yum install python-virtualenv
  2. Tell your system where to store the environment: virtualenv $HOME/myEnv
  3. Activate the environment: source $HOME/myEnv/bin/activate

Use your environment as you normally would use your system.

When you are done, type exit to close the environment.