Run neutron-debug with admin tenant in neutron-adv-test
Because neutron-debug create-probe needs admin role only, demo tenants
cannot create ports. neutron-debug is wrapped in order to run it only
with admin tenant.
Change-Id: I149d8e4e8fac6aa5c496b8f186aa0afb28bf81c2
Closes-Bug: #1269090
(cherry picked from commit 52a7b6ecba
)
This commit is contained in:
parent
b921bb386b
commit
ed079cc4c9
@ -179,6 +179,14 @@ function confirm_server_active {
|
||||
fi
|
||||
}
|
||||
|
||||
function neutron_debug_admin {
|
||||
local os_username=$OS_USERNAME
|
||||
local os_tenant_id=$OS_TENANT_ID
|
||||
source $TOP_DIR/openrc admin admin
|
||||
neutron-debug $@
|
||||
source $TOP_DIR/openrc $os_username $os_tenant_id
|
||||
}
|
||||
|
||||
function add_tenant {
|
||||
local TENANT=$1
|
||||
local USER=$2
|
||||
@ -234,7 +242,7 @@ function create_network {
|
||||
source $TOP_DIR/openrc $TENANT $TENANT
|
||||
local NET_ID=$(neutron net-create --tenant_id $TENANT_ID $NET_NAME $EXTRA| grep ' id ' | awk '{print $4}' )
|
||||
neutron subnet-create --ip_version 4 --tenant_id $TENANT_ID --gateway $GATEWAY $NET_ID $CIDR
|
||||
neutron-debug probe-create --device-owner compute $NET_ID
|
||||
neutron_debug_admin probe-create --device-owner compute $NET_ID
|
||||
source $TOP_DIR/openrc demo demo
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user