Always use virtualenv and pip to install tempest on Ubuntu
For ubuntu distro jobs there are no tempest plugins packages so drop the 'mixed setup' where tempest comes from a distro package and the plugins come from pip, and then fail to install into the system python environment. Change-Id: Ic146e011ec15889303061527e17cdc16ed914799
This commit is contained in:
parent
9de0b7a59f
commit
61f3c98680
@ -31,8 +31,18 @@
|
|||||||
with_items: "{{ tempest_services }}"
|
with_items: "{{ tempest_services }}"
|
||||||
when: tempest_services | length > 0
|
when: tempest_services | length > 0
|
||||||
|
|
||||||
- name: Gather variables for installation method
|
# NOTE(jrosser) we use source installs for temepest and it's plugins on ubuntu distro installs
|
||||||
include_vars: "{{ tempest_install_method }}_install.yml"
|
- name: Gather variables for source installs
|
||||||
|
include_vars: source_install.yml
|
||||||
|
when:
|
||||||
|
- ((tempest_install_method == 'source') or (tempest_install_method == 'distro' and ansible_distribution == 'Ubuntu'))
|
||||||
|
tags:
|
||||||
|
- always
|
||||||
|
|
||||||
|
- name: Gather variables for distro installs
|
||||||
|
include_vars: distro_install.yml
|
||||||
|
when:
|
||||||
|
- tempest_install_method == 'distro'
|
||||||
tags:
|
tags:
|
||||||
- always
|
- always
|
||||||
|
|
||||||
|
@ -31,7 +31,7 @@
|
|||||||
# in defaults as in case of non-integrated tests meta handlers from other roles might fail.
|
# in defaults as in case of non-integrated tests meta handlers from other roles might fail.
|
||||||
- name: Install Tempest packages from PIP
|
- name: Install Tempest packages from PIP
|
||||||
import_tasks: tempest_install_source.yml
|
import_tasks: tempest_install_source.yml
|
||||||
when: (tempest_install_method | default('source')) == 'source' or (tempest_plugin_install_source | default(False))
|
when: (tempest_install_method | default('source')) == 'source' or (tempest_install_method == 'distro' and ansible_distribution == 'Ubuntu')
|
||||||
|
|
||||||
- name: Install stackviz on venv
|
- name: Install stackviz on venv
|
||||||
import_role:
|
import_role:
|
||||||
|
@ -13,9 +13,6 @@
|
|||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
# Note(noonedeadpunk) When tempest_plugin_install_source is true, we do not
|
|
||||||
# want pip packages to be installed inside venv, since tempest itself is
|
|
||||||
# installed via system packages so that plugins will be visible for tempest.
|
|
||||||
- name: Install the python venv
|
- name: Install the python venv
|
||||||
import_role:
|
import_role:
|
||||||
name: "python_venv_build"
|
name: "python_venv_build"
|
||||||
@ -29,7 +26,6 @@
|
|||||||
- section: "tempest"
|
- section: "tempest"
|
||||||
option: "venv_tag"
|
option: "venv_tag"
|
||||||
value: "{{ tempest_venv_tag }}"
|
value: "{{ tempest_venv_tag }}"
|
||||||
when: tempest_install_method | default('source') == 'source'
|
|
||||||
|
|
||||||
- name: Get tempest plugins from git
|
- name: Get tempest plugins from git
|
||||||
git:
|
git:
|
||||||
@ -48,9 +44,7 @@
|
|||||||
pip:
|
pip:
|
||||||
name: "/opt/{{ item.name|replace('-', '_') }}_{{ item.branch|replace('/', '_') }}"
|
name: "/opt/{{ item.name|replace('-', '_') }}_{{ item.branch|replace('/', '_') }}"
|
||||||
state: "{{ tempest_pip_package_state }}"
|
state: "{{ tempest_pip_package_state }}"
|
||||||
virtualenv: "{{ tempest_plugin_install_source | ternary(omit, tempest_venv_bin | dirname) }}"
|
virtualenv: "{{ tempest_venv_bin | dirname }}"
|
||||||
executable: "{{ tempest_plugin_install_source | ternary(tempest_install_pip_executable, omit) }}"
|
|
||||||
virtualenv_site_packages: "{{ tempest_plugin_install_source | ternary(omit, 'no') }}"
|
|
||||||
extra_args: >-
|
extra_args: >-
|
||||||
{{ tempest_pip_install_args }}
|
{{ tempest_pip_install_args }}
|
||||||
--constraint {{ tempest_upper_constraints_url }}
|
--constraint {{ tempest_upper_constraints_url }}
|
||||||
@ -66,9 +60,7 @@
|
|||||||
pip:
|
pip:
|
||||||
name: "{{ item.package }}"
|
name: "{{ item.package }}"
|
||||||
state: "{{ tempest_pip_package_state }}"
|
state: "{{ tempest_pip_package_state }}"
|
||||||
virtualenv: "{{ tempest_plugin_install_source | ternary(omit, tempest_venv_bin | dirname) }}"
|
virtualenv: "{{ tempest_venv_bin | dirname }}"
|
||||||
executable: "{{ tempest_plugin_install_source | ternary(tempest_install_pip_executable, omit) }}"
|
|
||||||
virtualenv_site_packages: "{{ tempest_plugin_install_source | ternary(omit, 'no') }}"
|
|
||||||
extra_args: >-
|
extra_args: >-
|
||||||
{{ tempest_pip_install_args }}
|
{{ tempest_pip_install_args }}
|
||||||
--constraint {{ tempest_upper_constraints_url }}
|
--constraint {{ tempest_upper_constraints_url }}
|
||||||
|
@ -43,14 +43,6 @@ tempest_images_map:
|
|||||||
properties:
|
properties:
|
||||||
hw_firmware_type: uefi
|
hw_firmware_type: uefi
|
||||||
|
|
||||||
# Note(noonedeadpunk):
|
|
||||||
# Ubuntu does not publish tempest plugin packages. They do
|
|
||||||
# all their testing using the source-based installation of
|
|
||||||
# tempest.
|
|
||||||
# For mixed setup we are using source install tasks, except
|
|
||||||
# that we're deploying pip packages without venv.
|
|
||||||
tempest_plugin_install_source: "{{ ((tempest_install_method == 'distro') and (ansible_os_family | lower == 'debian')) | bool }}"
|
|
||||||
|
|
||||||
# Each tempest plugin could take the following arguments:
|
# Each tempest plugin could take the following arguments:
|
||||||
# - name:
|
# - name:
|
||||||
# repo: # when installing from a repo
|
# repo: # when installing from a repo
|
||||||
@ -68,7 +60,7 @@ _tempest_plugins:
|
|||||||
- name: cinder-tempest-plugin
|
- name: cinder-tempest-plugin
|
||||||
repo: https://opendev.org/openstack/cinder-tempest-plugin
|
repo: https://opendev.org/openstack/cinder-tempest-plugin
|
||||||
branch: master
|
branch: master
|
||||||
install: "{{ tempest_service_available_cinder | bool and not tempest_plugin_install_source }}"
|
install: "{{ tempest_service_available_cinder | bool }}"
|
||||||
cloudkitty:
|
cloudkitty:
|
||||||
- name: cloudkitty-tempest-plugin
|
- name: cloudkitty-tempest-plugin
|
||||||
repo: https://opendev.org/openstack/cloudkitty-tempest-plugin
|
repo: https://opendev.org/openstack/cloudkitty-tempest-plugin
|
||||||
@ -88,7 +80,7 @@ _tempest_plugins:
|
|||||||
- name: heat-tempest-plugin
|
- name: heat-tempest-plugin
|
||||||
repo: https://opendev.org/openstack/heat-tempest-plugin
|
repo: https://opendev.org/openstack/heat-tempest-plugin
|
||||||
branch: master
|
branch: master
|
||||||
install: "{{ tempest_service_available_heat | bool and not tempest_plugin_install_source }}"
|
install: "{{ tempest_service_available_heat | bool }}"
|
||||||
ironic:
|
ironic:
|
||||||
- name: ironic-tempest-plugin
|
- name: ironic-tempest-plugin
|
||||||
repo: https://opendev.org/openstack/ironic-tempest-plugin
|
repo: https://opendev.org/openstack/ironic-tempest-plugin
|
||||||
@ -133,7 +125,7 @@ _tempest_plugins:
|
|||||||
- name: neutron-tempest-plugin
|
- name: neutron-tempest-plugin
|
||||||
repo: https://opendev.org/openstack/neutron-tempest-plugin
|
repo: https://opendev.org/openstack/neutron-tempest-plugin
|
||||||
branch: master
|
branch: master
|
||||||
install: "{{ tempest_service_available_neutron | bool and not tempest_plugin_install_source }}"
|
install: "{{ tempest_service_available_neutron | bool }}"
|
||||||
novajoin:
|
novajoin:
|
||||||
- name: novajoin-tempest-plugin
|
- name: novajoin-tempest-plugin
|
||||||
repo: https://opendev.org/openstack/novajoin-tempest-plugin
|
repo: https://opendev.org/openstack/novajoin-tempest-plugin
|
||||||
|
Loading…
x
Reference in New Issue
Block a user