diskimage-builder/elements/pypi/post-install.d/00-unconfigure-pypi-mirror
Robert Collins 97bc5d7853 Allow using a pypi mirror to install via pip.
Using a custom pypi mirror can be very convenient, making image builds
substantially faster - because we create multiple virtual
environments we benefit more than single-virtualenv users would.

Change-Id: I997daf1f9477c447e1fb30818aea9e80a49b31a6
2013-08-10 22:07:30 +12:00

17 lines
231 B
Bash
Executable File

#!/bin/bash
set -eu
if [ -e ~/.pip/pip.conf.orig ]; then
mv ~/.pip/pip.conf{.orig,}
else
rm ~/.pip/pip.conf
fi
if [ -e ~/.pydistutils.cfg.orig ]; then
mv ~/.pydistutils.cfg{.orig,}
else
rm ~/.pydistutils.cfg
fi