test/openstack: Clean up the test
This is done as part of the work to fix currently existing CI job using this particular test suite. Signed-off-by: Michal Berger <michalx.berger@intel.com> Change-Id: Id5e9e8a814fb3025f192871650b8aa317f2de910 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7440 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com> Reviewed-by: Karol Latecki <karol.latecki@intel.com> Reviewed-by: Maciej Szwed <maciej.szwed@intel.com> Reviewed-by: Maciej Wawryk <maciejx.wawryk@intel.com>
This commit is contained in:
parent
994be25fe1
commit
0c25e6fbbc
@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
testdir=$(readlink -f $(dirname $0))
|
testdir=$(readlink -f $(dirname $0))
|
||||||
rootdir=$(readlink -f $testdir/../..)
|
rootdir=$(readlink -f $testdir/../..)
|
||||||
|
source "$rootdir/test/common/autotest_common.sh"
|
||||||
|
|
||||||
function usage() {
|
function usage() {
|
||||||
[[ -n $2 ]] && (
|
[[ -n $2 ]] && (
|
||||||
@ -31,25 +32,35 @@ while getopts 'h-:' optchar; do
|
|||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
cd /opt/stack/devstack
|
if [[ -e /opt/stack/devstack/unstack.sh ]]; then
|
||||||
su -c "./unstack.sh" -s /bin/bash stack
|
cd /opt/stack/devstack
|
||||||
|
su -c "./unstack.sh" -s /bin/bash stack
|
||||||
|
fi
|
||||||
|
|
||||||
cd /opt/stack
|
mkdir -p /opt/stack
|
||||||
rm -rf cinder devstack glance keystone heat horizon neutron nova placement requirements tacker tacker-horizon tempest
|
rm -rf /opt/stack/*
|
||||||
|
|
||||||
r=0
|
r=0
|
||||||
until [[ $r -ge 20 ]]; do
|
until ((++r >= 20)); do
|
||||||
if [[ $branch == "master" ]]; then
|
if [[ $branch == "master" ]]; then
|
||||||
su -c "git clone --depth 1 https://opendev.org/openstack-dev/devstack" -s /bin/bash stack && break
|
git clone --depth 1 https://opendev.org/openstack-dev/devstack /opt/stack/devstack && break
|
||||||
else
|
else
|
||||||
su -c "git clone --depth 1 https://opendev.org/openstack-dev/devstack -b stable/$branch" -s /bin/bash stack && break
|
git clone --depth 1 https://opendev.org/openstack-dev/devstack -b "stable/$branch" /opt/stack/devstack && break
|
||||||
fi
|
fi
|
||||||
r=$((r + 1))
|
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# Check if we reached max retries count
|
||||||
|
((r < 20))
|
||||||
|
|
||||||
|
git clone https://github.com/openstack/os-brick.git /opt/stack/os-brick
|
||||||
|
cd /opt/stack/os-brick
|
||||||
|
python3 ./setup.py install
|
||||||
|
|
||||||
cp $rootdir/scripts/vagrant/local.conf /opt/stack/devstack/local.conf
|
cp $rootdir/scripts/vagrant/local.conf /opt/stack/devstack/local.conf
|
||||||
|
|
||||||
cd /opt/stack/devstack
|
cd /opt/stack/devstack
|
||||||
sudo sed -i "s|http://download.cirros-cloud.net|https://download.cirros-cloud.net|g" stackrc
|
./tools/create-stack-user.sh
|
||||||
|
chown -R stack:stack /opt/stack
|
||||||
su -c "./stack.sh" -s /bin/bash stack
|
su -c "./stack.sh" -s /bin/bash stack
|
||||||
source openrc admin admin
|
source openrc admin admin
|
||||||
openstack volume type create SPDK --public
|
openstack volume type create SPDK --public
|
||||||
|
@ -3,11 +3,13 @@
|
|||||||
testdir=$(readlink -f $(dirname $0))
|
testdir=$(readlink -f $(dirname $0))
|
||||||
rootdir=$(readlink -f $testdir/../..)
|
rootdir=$(readlink -f $testdir/../..)
|
||||||
rpc_py=$rootdir/scripts/rpc.py
|
rpc_py=$rootdir/scripts/rpc.py
|
||||||
|
|
||||||
|
set -- "--iso" "--transport=rdma" "$@"
|
||||||
|
|
||||||
source $rootdir/test/common/autotest_common.sh
|
source $rootdir/test/common/autotest_common.sh
|
||||||
source $rootdir/test/nvmf/common.sh
|
source $rootdir/test/nvmf/common.sh
|
||||||
TEST_TRANSPORT='rdma'
|
|
||||||
|
|
||||||
nvmftestinit
|
HUGE_EVEN_ALLOC=yes HUGEMEM=1024 nvmftestinit
|
||||||
|
|
||||||
function finish_test() {
|
function finish_test() {
|
||||||
{
|
{
|
||||||
@ -41,6 +43,8 @@ sudo systemctl restart devstack@c-*
|
|||||||
sleep 10
|
sleep 10
|
||||||
timing_exit restart_cinder
|
timing_exit restart_cinder
|
||||||
|
|
||||||
|
rxe_cfg status
|
||||||
|
|
||||||
# Start testing spdk with openstack using tempest (openstack tool that allow testing an openstack functionalities)
|
# Start testing spdk with openstack using tempest (openstack tool that allow testing an openstack functionalities)
|
||||||
# In this tests is checked if spdk can correctly cooperate with openstack spdk driver
|
# In this tests is checked if spdk can correctly cooperate with openstack spdk driver
|
||||||
timing_enter tempest_tests
|
timing_enter tempest_tests
|
||||||
|
Loading…
Reference in New Issue
Block a user