Test for python-pip as well as pip
On Red Hat, CentOS and Fedora systems, the pip binary will be called python-pip instead of pip. This commit makes the pip module also check for python-pip. The reason we check for python-pip *first*, is to have ansible fail on not finding 'pip' and reporting *that*. This is consistent with current behaviour and will not confuse users of Debian et al., where the 'python-pip' binary never exists. Tested on Fedora 18 and Ubuntu 12.04.
This commit is contained in:
parent
8739b87f42
commit
c482104cda
1 changed files with 3 additions and 1 deletions
2
pip
2
pip
|
@ -135,6 +135,8 @@ def main():
|
|||
out += out_venv
|
||||
err += err_venv
|
||||
|
||||
pip = module.get_bin_path('python-pip', False, ['%s/bin' % env])
|
||||
if not pip:
|
||||
pip = module.get_bin_path('pip', True, ['%s/bin' % env])
|
||||
|
||||
state = module.params['state']
|
||||
|
|
Loading…
Reference in a new issue