summaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
authorFotis Gimian <fgimiansoftware@gmail.com>2013-06-03 19:43:14 +1000
committerFotis Gimian <fgimiansoftware@gmail.com>2013-06-03 19:43:14 +1000
commit5617ad20f4515254d9ac7b9cdef63de59ebece08 (patch)
tree64af668eacb405c2074983d3c6b825c3d147702e /manifests
parent3c606c95e12be941529fdf86c14f3f35bcddbf69 (diff)
Added environment attribute to the pip class which allows for users to override environment variables like LD_LIBRARY_PATH and ORACLE_HOME which are needed to install packages like cx_Oracle.
Diffstat (limited to 'manifests')
-rw-r--r--manifests/pip.pp5
1 files changed, 4 insertions, 1 deletions
diff --git a/manifests/pip.pp b/manifests/pip.pp
index b40b916..73f4cdc 100644
--- a/manifests/pip.pp
+++ b/manifests/pip.pp
@@ -33,7 +33,8 @@ define python::pip (
$url = false,
$owner = 'root',
$group = 'root',
- $proxy = false
+ $proxy = false,
+ environment = []
) {
# Parameter validation
@@ -62,6 +63,7 @@ define python::pip (
command => "${virtualenv}/bin/pip install ${proxy_flag} ${source}",
unless => "${virtualenv}/bin/pip freeze | grep -i -e ${grep_regex}",
user => $owner,
+ environment => $environment,
}
}
@@ -70,6 +72,7 @@ define python::pip (
command => "echo y | ${virtualenv}/bin/pip uninstall ${proxy_flag} ${name}",
onlyif => "${virtualenv}/bin/pip freeze | grep -i -e ${grep_regex}",
user => $owner,
+ environment => $environment,
}
}
}