feat: add option for pip-envrionment-variables
This commit is contained in:
parent
6e819c0e97
commit
57e310076f
|
@ -51,6 +51,14 @@ A list of packages to install with pip. Examples below:
|
|||
- name: docker
|
||||
virtualenv: /my_app/venv
|
||||
|
||||
To pass environment variables to `pip` use `pip_environment_variables`. (This is usefull for proxy configuration)
|
||||
|
||||
```
|
||||
pip_environment_variables:
|
||||
http_proxy: "proxy.example.com"
|
||||
```
|
||||
|
||||
|
||||
## Dependencies
|
||||
|
||||
None.
|
||||
|
|
|
@ -2,5 +2,6 @@
|
|||
# For Python 3, use python3-pip.
|
||||
pip_package: python3-pip
|
||||
pip_executable: "{{ 'pip3' if pip_package.startswith('python3') else 'pip' }}"
|
||||
pip_environment_variables: []
|
||||
|
||||
pip_install_packages: []
|
||||
|
|
|
@ -12,3 +12,4 @@
|
|||
state: "{{ item.state | default(omit) }}"
|
||||
executable: "{{ pip_executable }}"
|
||||
loop: "{{ pip_install_packages }}"
|
||||
environment: "{{ pip_environment_variables }}"
|
||||
|
|
Loading…
Reference in New Issue