Add pip-and-virtualenv element

This element allows installation of pip and virtualenv from either
distro packages or git.

Change-Id: Id294f0936c8fef8a3b27a415bfcc93b3f327e104
Depends-On: I731cc8a0f5bfeda8f17a78c33b9f44062323a361
This commit is contained in:
Gregory Haynes 2015-10-27 01:49:05 +00:00 committed by Lucas Alvares Gomes
parent 2b28993fb8
commit db3ee03672
5 changed files with 29 additions and 0 deletions

View File

@ -0,0 +1,12 @@
==================
pip-and-virtualenv
==================
This element installs pip and virtualenv in the image. If the package
installtype is used then these programs are installed from distribution
packages. If the source installtype is used these programs are installed
from get-pip.py and pip (respectively).
To install pip and virtualenv from package:
export DIB_INSTALLTYPE_pip_and_virtualenv=package

View File

@ -0,0 +1,2 @@
package-installs
source-repositories

View File

@ -0,0 +1,10 @@
#!/bin/bash
if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then
set -x
fi
set -eu
set -o pipefail
python /tmp/get-pip.py
pip install virtualenv

View File

@ -0,0 +1,4 @@
python-pip:
installtype: package
python-virtualenv:
installtype: package

View File

@ -0,0 +1 @@
get-pip-py file /tmp/get-pip.py https://bootstrap.pypa.io/get-pip.py