Browse Source

Merge "Add option for default pip package install"

Zuul 9 months ago
parent
commit
c4af997fe5

+ 4
- 0
defaults/main.yml View File

@@ -121,3 +121,7 @@ repo_pip_packages:
121 121
   - wheel
122 122
 
123 123
 repo_build_store_pip_sources: false
124
+
125
+# Default python packages which will be installed
126
+# into every venv.
127
+repo_venv_default_pip_packages: []

+ 6
- 0
releasenotes/notes/custom-pip-package-add-4c17638c6e5b3373.yaml View File

@@ -0,0 +1,6 @@
1
+---
2
+features:
3
+  - The option ``repo_venv_default_pip_packages`` has been added which will
4
+    allow deployers to insert any packages into a service venv as needed.
5
+    The option expects a list of strings which are valid python package names as
6
+    found on PYPI.

+ 1
- 1
templates/venv-build-options.txt.j2 View File

@@ -146,4 +146,4 @@ VENV_CREATE_COMMAND="{{ repo_build_venv_command_options }}"
146 146
 {#                                                                          #}
147 147
 {# Finally, we output the alphabetically sorted requirements.               #}
148 148
 {#                                                                          #}
149
-ROLE_VENV_REQUIREMENTS="{{ (requirement_list | sort) | join(' ') }}"
149
+ROLE_VENV_REQUIREMENTS="{{ (repo_venv_default_pip_packages | union(requirement_list) | sort) | join(' ') }}"

Loading…
Cancel
Save