ca28815acc
Currently in packstack deployment, we are collecting logs once the deployment finishes and then we run tempest tests and collect tempest related logs. If the tempest tests fails, we have no openstack services logs with tempest api calls in service logs, it is very hard to find out what is causing the failure. Copying the openstack services logs just after tempest runs finishes will more info about the failure. It also disables the copy log operation once packstack deployment finishes. Change-Id: I5ab038a49eeabe564650894f50c3b51e33e93fd2 Signed-off-by: Chandan Kumar (raukadah) <chkumar@redhat.com>
73 lines
2.7 KiB
YAML
73 lines
2.7 KiB
YAML
- hosts: all
|
|
vars:
|
|
test_demo_user: "{{ test_demo is defined }}"
|
|
tasks:
|
|
# Disable packstack logs copy once packstack deployment finishes
|
|
# packstack-integration-tempest role is inherited from
|
|
# x/packstack project
|
|
- name: Install packstack allinone
|
|
import_role:
|
|
name: packstack-integration-tempest
|
|
environment:
|
|
COPY_LOGS: false
|
|
# setup-tempest-user, setup-stack-user and setup-devstack-source-dirs
|
|
# are inherited from openstack/devstack
|
|
- name: Setup Stack user
|
|
include_role:
|
|
name: setup-stack-user
|
|
- name: Setup Tempest user
|
|
include_role:
|
|
name: setup-tempest-user
|
|
- name: Setup Tempest user
|
|
include_role:
|
|
name: setup-devstack-source-dirs
|
|
# setup-tempest-* and acl-devstack-files roles are inherited from
|
|
# openstack/tempest project
|
|
- name: Setup Tempest Run Directory
|
|
include_role:
|
|
name: setup-tempest-run-dir
|
|
- name: Setup Tempest Data Directory
|
|
include_role:
|
|
name: setup-tempest-data-dir
|
|
- name: ACL devstack files
|
|
include_role:
|
|
name: acl-devstack-files
|
|
- name: Prepare keystonerc credentials generated by packstack
|
|
include_role:
|
|
name: create-keystonerc-files
|
|
- name: Create clouds.yaml file
|
|
include_role:
|
|
name: create-clouds-yaml-file
|
|
vars:
|
|
cloudname: "packstack-admin"
|
|
source_credentials_commands: "source {{ ansible_user_dir }}/keystonerc_admin"
|
|
- name: Generate configuration file for Tempest
|
|
include_role:
|
|
name: generate-tempestconf-file
|
|
vars:
|
|
source_credentials_commands: "source {{ ansible_user_dir }}/keystonerc_{{ user }}"
|
|
# Let's create tempest.conf with admin permissions needed for
|
|
# tempest accounts file generation
|
|
- name: Generate configuration file for Tempest as admin
|
|
include_role:
|
|
name: generate-tempestconf-file
|
|
vars:
|
|
aditional_tempestconf_params: "object-storage.operator_role Member"
|
|
output_path: "/etc/openstack/tempest_admin.conf"
|
|
source_credentials_commands: "source {{ ansible_user_dir }}/keystonerc_admin"
|
|
test_demo_user: False
|
|
user: admin
|
|
when: test_demo is defined
|
|
- name: Generate accounts file for Tempest
|
|
include_role:
|
|
name: generate-accounts-file
|
|
vars:
|
|
accounts_file_destination: "/etc/openstack"
|
|
source_credentials_commands: "source {{ ansible_user_dir }}/keystonerc_admin"
|
|
tempest_config_file: "/etc/openstack/tempest_admin.conf"
|
|
when: test_demo is defined
|
|
# run-tempest role is inherited from openstack/tempest project
|
|
- name: Run Tempest Tests
|
|
include_role:
|
|
name: run-tempest
|