tripleo-ci/roles/build-containers/tasks/venv_setup.yml
Ronelle Landy 450a40cc2a Add support for OSP containers in new build process
This patch:
 - adds support for excludes from osp_branch
 - uses the OSP repo versions in venv setup
when running on downstream builds
 - allows for the use of a custom container name
prefix to deal with the rhel/redhat switch up using
container_name_prefix var.

Change-Id: I6ea1b57f0349044a5852172b8b4b92f718e5c4bf
2020-07-08 14:18:39 +05:30

55 lines
1.9 KiB
YAML

- name: Make sure we have pip
include_role:
name: ensure-pip
- name: https://bugs.launchpad.net/tripleo/+bug/1862941 install six>=1.14.0
pip:
name:
- six>=1.14.0
extra_args: --user
- name: Install deps from upper-constraints
when: zuul_internal is undefined
pip:
extra_args: "-c {{ openstack_git_root }}/requirements/upper-constraints.txt"
requirements: "{{ openstack_git_root }}/{{ item }}/requirements.txt"
virtualenv: "{{ workspace }}/venv_build"
virtualenv_python: "{{ virtualenv_python[ansible_distribution_major_version|int] }}"
with_items:
- kolla
- tripleo-common
- python-tripleoclient
- tripleo-ansible
- name: Install deps from requirements
when: zuul_internal is defined
pip:
requirements: "{{ openstack_git_root }}/{{ item }}/requirements.txt"
virtualenv: "{{ workspace }}/venv_build"
virtualenv_python: "{{ virtualenv_python[ansible_distribution_major_version|int] }}"
with_items:
- kolla
- openstack-tripleo-common
- python-tripleoclient
- tripleo-ansible
- name: Installation from source
pip:
name:
- "file://{{ openstack_git_root }}/kolla"
- "file://{{ openstack_git_root }}/{% if zuul_internal is defined %}openstack-{% endif %}tripleo-common"
- "file://{{ openstack_git_root }}/python-tripleoclient"
- "file://{{ openstack_git_root }}/tripleo-ansible"
- decorator
virtualenv: "{{ workspace }}/venv_build"
virtualenv_python: "{{ virtualenv_python[ansible_distribution_major_version|int] }}"
- name: set template override
set_fact:
kolla_override_path: >-
{% if zuul_internal is defined -%}
"{{ openstack_git_root }}/openstack-tripleo-common/container-images/tripleo_kolla_template_overrides.j2"
{% else -%}
"{{ openstack_git_root }}/tripleo-common/container-images/tripleo_kolla_template_overrides.j2"
{% endif %}