From 6a6f9c039fa6a502de52ab9a7366174070ddff3c Mon Sep 17 00:00:00 2001 From: yatin Date: Wed, 17 May 2017 15:59:01 +0530 Subject: [PATCH] Use 'virt_type=kvm' in devstack vm if supported If the devstack vm supports nested virtualization we should use it. This can done using by setting: DEVSTACK_GATE_LIBVIRT_TYPE=kvm. This will increase the performance in gate jobs. Change-Id: I2439de036dfec2ada3c92c2d4b71c73b5f41a518 (cherry picked from commit 34efcdfcafad3108e54fd4351a414f3a74e1ef6f) (cherry picked from commit 907eeb28da0a03abb5b1c6702e53a32b576fec29) --- magnum/tests/contrib/gate_hook.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/magnum/tests/contrib/gate_hook.sh b/magnum/tests/contrib/gate_hook.sh index e0d1f7d9ac..1da48c95e2 100755 --- a/magnum/tests/contrib/gate_hook.sh +++ b/magnum/tests/contrib/gate_hook.sh @@ -27,6 +27,11 @@ if [ "${coe}${special}" != "k8s-ironic" ]; then export DEVSTACK_LOCAL_CONFIG+=$'\n'"enable_plugin octavia https://github.com/openstack/octavia" fi +if egrep --quiet '(vmx|svm)' /proc/cpuinfo; then + export DEVSTACK_GATE_LIBVIRT_TYPE=kvm +fi + + if [ "$coe" = "mesos" ]; then export DEVSTACK_LOCAL_CONFIG+=$'\n'"MAGNUM_GUEST_IMAGE_URL=https://fedorapeople.org/groups/magnum/ubuntu-mesos-newton.qcow2" elif [ "$coe" = "k8s-coreos" ]; then