Use a separate requirements file for venv packages

This commit is contained in:
Will Miller 2018-08-28 12:18:58 +00:00
parent f9638bc28b
commit 66f5f8edf1
3 changed files with 13 additions and 4 deletions

View File

@ -10,9 +10,6 @@ system_requirements:
# not exist at this location, one will be created.
virtualenv_path: "{{ '/'.join([ansible_env['HOME'], 'tenks-venv']) }}"
python_requirements:
- virtualbmc
# Naming scheme for bridges created by tenks for physical networks is
# {{ bridge_prefix + i }}, where `i` is the index of the physical network in
# physnet_mappings (sorted alphabetically by key).
@ -33,3 +30,8 @@ veth_vm_ovs_suffix: '-ovs'
veth_vm_source_suffix: '-tap'
console_log_directory: /var/log/tenks/console_logs/
# The URL of the upper constraints file to pass to pip when installing Python
# packages.
python_upper_contraints_url: >-
https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt

View File

@ -46,5 +46,8 @@
- name: Ensure Python requirements are installed
pip:
name: "{{ python_requirements }}"
requirements: >-
{{ '/'.join([(playbook_dir | dirname), 'venv-requirements.txt']) }}
extra_args: >-
-c {{ python_upper_contraints_url }}
virtualenv: "{{ virtualenv_path }}"

4
venv-requirements.txt Normal file
View File

@ -0,0 +1,4 @@
# This file contains the Python packages that are needed in the Tenks virtual
# env.
virtualbmc>=1.4.0 # Apache