Merge "Use --tenant-id, not --tenant_id"
This commit is contained in:
commit
cbe79ba27d
@ -365,7 +365,7 @@ create_cinder_accounts() {
|
|||||||
CINDER_USER=$(keystone user-create \
|
CINDER_USER=$(keystone user-create \
|
||||||
--name=cinder \
|
--name=cinder \
|
||||||
--pass="$SERVICE_PASSWORD" \
|
--pass="$SERVICE_PASSWORD" \
|
||||||
--tenant_id $SERVICE_TENANT \
|
--tenant-id $SERVICE_TENANT \
|
||||||
--email=cinder@example.com \
|
--email=cinder@example.com \
|
||||||
| grep " id " | get_field 2)
|
| grep " id " | get_field 2)
|
||||||
keystone user-role-add \
|
keystone user-role-add \
|
||||||
|
@ -149,11 +149,11 @@ create_ironic_accounts() {
|
|||||||
IRONIC_USER=$(keystone user-create \
|
IRONIC_USER=$(keystone user-create \
|
||||||
--name=ironic \
|
--name=ironic \
|
||||||
--pass="$SERVICE_PASSWORD" \
|
--pass="$SERVICE_PASSWORD" \
|
||||||
--tenant_id $SERVICE_TENANT \
|
--tenant-id $SERVICE_TENANT \
|
||||||
--email=ironic@example.com \
|
--email=ironic@example.com \
|
||||||
| grep " id " | get_field 2)
|
| grep " id " | get_field 2)
|
||||||
keystone user-role-add \
|
keystone user-role-add \
|
||||||
--tenant_id $SERVICE_TENANT \
|
--tenant-id $SERVICE_TENANT \
|
||||||
--user_id $IRONIC_USER \
|
--user_id $IRONIC_USER \
|
||||||
--role_id $ADMIN_ROLE
|
--role_id $ADMIN_ROLE
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
@ -142,7 +142,7 @@ function create_marconi_accounts() {
|
|||||||
|
|
||||||
MARCONI_USER=$(get_id keystone user-create --name=marconi \
|
MARCONI_USER=$(get_id keystone user-create --name=marconi \
|
||||||
--pass="$SERVICE_PASSWORD" \
|
--pass="$SERVICE_PASSWORD" \
|
||||||
--tenant_id $SERVICE_TENANT \
|
--tenant-id $SERVICE_TENANT \
|
||||||
--email=marconi@example.com)
|
--email=marconi@example.com)
|
||||||
keystone user-role-add --tenant-id $SERVICE_TENANT \
|
keystone user-role-add --tenant-id $SERVICE_TENANT \
|
||||||
--user-id $MARCONI_USER \
|
--user-id $MARCONI_USER \
|
||||||
|
14
lib/neutron
14
lib/neutron
@ -328,7 +328,7 @@ function create_neutron_accounts() {
|
|||||||
NEUTRON_USER=$(keystone user-create \
|
NEUTRON_USER=$(keystone user-create \
|
||||||
--name=neutron \
|
--name=neutron \
|
||||||
--pass="$SERVICE_PASSWORD" \
|
--pass="$SERVICE_PASSWORD" \
|
||||||
--tenant_id $SERVICE_TENANT \
|
--tenant-id $SERVICE_TENANT \
|
||||||
--email=neutron@example.com \
|
--email=neutron@example.com \
|
||||||
| grep " id " | get_field 2)
|
| grep " id " | get_field 2)
|
||||||
keystone user-role-add \
|
keystone user-role-add \
|
||||||
@ -357,7 +357,7 @@ function create_neutron_initial_network() {
|
|||||||
|
|
||||||
# Create a small network
|
# Create a small network
|
||||||
# Since neutron command is executed in admin context at this point,
|
# Since neutron command is executed in admin context at this point,
|
||||||
# ``--tenant_id`` needs to be specified.
|
# ``--tenant-id`` needs to be specified.
|
||||||
if is_baremetal; then
|
if is_baremetal; then
|
||||||
if [[ "$PUBLIC_INTERFACE" == '' || "$OVS_PHYSICAL_BRIDGE" == '' ]]; then
|
if [[ "$PUBLIC_INTERFACE" == '' || "$OVS_PHYSICAL_BRIDGE" == '' ]]; then
|
||||||
die $LINENO "Neutron settings for baremetal not set.. exiting"
|
die $LINENO "Neutron settings for baremetal not set.. exiting"
|
||||||
@ -367,16 +367,16 @@ function create_neutron_initial_network() {
|
|||||||
sudo ip addr del $IP dev $PUBLIC_INTERFACE
|
sudo ip addr del $IP dev $PUBLIC_INTERFACE
|
||||||
sudo ip addr add $IP dev $OVS_PHYSICAL_BRIDGE
|
sudo ip addr add $IP dev $OVS_PHYSICAL_BRIDGE
|
||||||
done
|
done
|
||||||
NET_ID=$(neutron net-create $PHYSICAL_NETWORK --tenant_id $TENANT_ID --provider:network_type flat --provider:physical_network "$PHYSICAL_NETWORK" | grep ' id ' | get_field 2)
|
NET_ID=$(neutron net-create $PHYSICAL_NETWORK --tenant-id $TENANT_ID --provider:network_type flat --provider:physical_network "$PHYSICAL_NETWORK" | grep ' id ' | get_field 2)
|
||||||
die_if_not_set $LINENO NET_ID "Failure creating NET_ID for $PHYSICAL_NETWORK $TENANT_ID"
|
die_if_not_set $LINENO NET_ID "Failure creating NET_ID for $PHYSICAL_NETWORK $TENANT_ID"
|
||||||
SUBNET_ID=$(neutron subnet-create --tenant_id $TENANT_ID --ip_version 4 ${ALLOCATION_POOL:+--allocation-pool $ALLOCATION_POOL} --gateway $NETWORK_GATEWAY --name $PRIVATE_SUBNET_NAME $NET_ID $FIXED_RANGE | grep ' id ' | get_field 2)
|
SUBNET_ID=$(neutron subnet-create --tenant-id $TENANT_ID --ip_version 4 ${ALLOCATION_POOL:+--allocation-pool $ALLOCATION_POOL} --gateway $NETWORK_GATEWAY --name $PRIVATE_SUBNET_NAME $NET_ID $FIXED_RANGE | grep ' id ' | get_field 2)
|
||||||
die_if_not_set $LINENO SUBNET_ID "Failure creating SUBNET_ID for $TENANT_ID"
|
die_if_not_set $LINENO SUBNET_ID "Failure creating SUBNET_ID for $TENANT_ID"
|
||||||
sudo ifconfig $OVS_PHYSICAL_BRIDGE up
|
sudo ifconfig $OVS_PHYSICAL_BRIDGE up
|
||||||
sudo route add default gw $NETWORK_GATEWAY dev $OVS_PHYSICAL_BRIDGE
|
sudo route add default gw $NETWORK_GATEWAY dev $OVS_PHYSICAL_BRIDGE
|
||||||
else
|
else
|
||||||
NET_ID=$(neutron net-create --tenant_id $TENANT_ID "$PRIVATE_NETWORK_NAME" | grep ' id ' | get_field 2)
|
NET_ID=$(neutron net-create --tenant-id $TENANT_ID "$PRIVATE_NETWORK_NAME" | grep ' id ' | get_field 2)
|
||||||
die_if_not_set $LINENO NET_ID "Failure creating NET_ID for $PHYSICAL_NETWORK $TENANT_ID"
|
die_if_not_set $LINENO NET_ID "Failure creating NET_ID for $PHYSICAL_NETWORK $TENANT_ID"
|
||||||
SUBNET_ID=$(neutron subnet-create --tenant_id $TENANT_ID --ip_version 4 --gateway $NETWORK_GATEWAY --name $PRIVATE_SUBNET_NAME $NET_ID $FIXED_RANGE | grep ' id ' | get_field 2)
|
SUBNET_ID=$(neutron subnet-create --tenant-id $TENANT_ID --ip_version 4 --gateway $NETWORK_GATEWAY --name $PRIVATE_SUBNET_NAME $NET_ID $FIXED_RANGE | grep ' id ' | get_field 2)
|
||||||
die_if_not_set $LINENO SUBNET_ID "Failure creating SUBNET_ID for $TENANT_ID"
|
die_if_not_set $LINENO SUBNET_ID "Failure creating SUBNET_ID for $TENANT_ID"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@ -384,7 +384,7 @@ function create_neutron_initial_network() {
|
|||||||
# Create a router, and add the private subnet as one of its interfaces
|
# Create a router, and add the private subnet as one of its interfaces
|
||||||
if [[ "$Q_L3_ROUTER_PER_TENANT" == "True" ]]; then
|
if [[ "$Q_L3_ROUTER_PER_TENANT" == "True" ]]; then
|
||||||
# create a tenant-owned router.
|
# create a tenant-owned router.
|
||||||
ROUTER_ID=$(neutron router-create --tenant_id $TENANT_ID $Q_ROUTER_NAME | grep ' id ' | get_field 2)
|
ROUTER_ID=$(neutron router-create --tenant-id $TENANT_ID $Q_ROUTER_NAME | grep ' id ' | get_field 2)
|
||||||
die_if_not_set $LINENO ROUTER_ID "Failure creating ROUTER_ID for $TENANT_ID $Q_ROUTER_NAME"
|
die_if_not_set $LINENO ROUTER_ID "Failure creating ROUTER_ID for $TENANT_ID $Q_ROUTER_NAME"
|
||||||
else
|
else
|
||||||
# Plugin only supports creating a single router, which should be admin owned.
|
# Plugin only supports creating a single router, which should be admin owned.
|
||||||
|
2
lib/nova
2
lib/nova
@ -318,7 +318,7 @@ create_nova_accounts() {
|
|||||||
NOVA_USER=$(keystone user-create \
|
NOVA_USER=$(keystone user-create \
|
||||||
--name=nova \
|
--name=nova \
|
||||||
--pass="$SERVICE_PASSWORD" \
|
--pass="$SERVICE_PASSWORD" \
|
||||||
--tenant_id $SERVICE_TENANT \
|
--tenant-id $SERVICE_TENANT \
|
||||||
--email=nova@example.com \
|
--email=nova@example.com \
|
||||||
| grep " id " | get_field 2)
|
| grep " id " | get_field 2)
|
||||||
keystone user-role-add \
|
keystone user-role-add \
|
||||||
|
@ -56,7 +56,7 @@ function create_savanna_accounts() {
|
|||||||
SAVANNA_USER=$(keystone user-create \
|
SAVANNA_USER=$(keystone user-create \
|
||||||
--name=savanna \
|
--name=savanna \
|
||||||
--pass="$SERVICE_PASSWORD" \
|
--pass="$SERVICE_PASSWORD" \
|
||||||
--tenant_id $SERVICE_TENANT \
|
--tenant-id $SERVICE_TENANT \
|
||||||
--email=savanna@example.com \
|
--email=savanna@example.com \
|
||||||
| grep " id " | get_field 2)
|
| grep " id " | get_field 2)
|
||||||
keystone user-role-add \
|
keystone user-role-add \
|
||||||
|
@ -514,7 +514,7 @@ function create_swift_accounts() {
|
|||||||
ADMIN_ROLE=$(keystone role-list | awk "/ admin / { print \$2 }")
|
ADMIN_ROLE=$(keystone role-list | awk "/ admin / { print \$2 }")
|
||||||
|
|
||||||
SWIFT_USER=$(keystone user-create --name=swift --pass="$SERVICE_PASSWORD" \
|
SWIFT_USER=$(keystone user-create --name=swift --pass="$SERVICE_PASSWORD" \
|
||||||
--tenant_id $SERVICE_TENANT --email=swift@example.com | grep " id " | get_field 2)
|
--tenant-id $SERVICE_TENANT --email=swift@example.com | grep " id " | get_field 2)
|
||||||
keystone user-role-add --tenant-id $SERVICE_TENANT --user-id $SWIFT_USER --role-id $ADMIN_ROLE
|
keystone user-role-add --tenant-id $SERVICE_TENANT --user-id $SWIFT_USER --role-id $ADMIN_ROLE
|
||||||
|
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
@ -64,7 +64,7 @@ create_trove_accounts() {
|
|||||||
TROVE_USER=$(keystone user-create \
|
TROVE_USER=$(keystone user-create \
|
||||||
--name=trove \
|
--name=trove \
|
||||||
--pass="$SERVICE_PASSWORD" \
|
--pass="$SERVICE_PASSWORD" \
|
||||||
--tenant_id $SERVICE_TENANT \
|
--tenant-id $SERVICE_TENANT \
|
||||||
--email=trove@example.com \
|
--email=trove@example.com \
|
||||||
| grep " id " | get_field 2)
|
| grep " id " | get_field 2)
|
||||||
keystone user-role-add --tenant-id $SERVICE_TENANT \
|
keystone user-role-add --tenant-id $SERVICE_TENANT \
|
||||||
|
Loading…
Reference in New Issue
Block a user