Merge "Use identity V3 API for endpoint creation"
This commit is contained in:
commit
aaae79b095
@ -815,6 +815,8 @@ function get_or_create_service {
|
|||||||
openstack service show $2 -f value -c id 2>/dev/null ||
|
openstack service show $2 -f value -c id 2>/dev/null ||
|
||||||
# Creates new service if not exists
|
# Creates new service if not exists
|
||||||
openstack service create \
|
openstack service create \
|
||||||
|
--os-url $KEYSTONE_SERVICE_URI_V3 \
|
||||||
|
--os-identity-api-version=3 \
|
||||||
$2 \
|
$2 \
|
||||||
--name $1 \
|
--name $1 \
|
||||||
--description="$3" \
|
--description="$3" \
|
||||||
@ -823,29 +825,56 @@ function get_or_create_service {
|
|||||||
echo $service_id
|
echo $service_id
|
||||||
}
|
}
|
||||||
|
|
||||||
# Gets or creates endpoint
|
# Create an endpoint with a specific interface
|
||||||
# Usage: get_or_create_endpoint <service> <region> <publicurl> <adminurl> <internalurl>
|
# Usage: _get_or_create_endpoint_with_interface <service> <interface> <url> <region>
|
||||||
function get_or_create_endpoint {
|
function _get_or_create_endpoint_with_interface {
|
||||||
# Gets endpoint id
|
|
||||||
local endpoint_id=$(openstack endpoint list \
|
local endpoint_id=$(openstack endpoint list \
|
||||||
--column "ID" \
|
--os-url $KEYSTONE_SERVICE_URI_V3 \
|
||||||
--column "Region" \
|
--os-identity-api-version=3 \
|
||||||
--column "Service Name" \
|
--service $1 \
|
||||||
| grep " $2 " \
|
--interface $2 \
|
||||||
| grep " $1 " | get_field 1)
|
--region $4 \
|
||||||
|
-c ID -f value)
|
||||||
if [[ -z "$endpoint_id" ]]; then
|
if [[ -z "$endpoint_id" ]]; then
|
||||||
# Creates new endpoint
|
# Creates new endpoint
|
||||||
endpoint_id=$(openstack endpoint create \
|
endpoint_id=$(openstack endpoint create \
|
||||||
$1 \
|
--os-url $KEYSTONE_SERVICE_URI_V3 \
|
||||||
--region $2 \
|
--os-identity-api-version=3 \
|
||||||
--publicurl $3 \
|
$1 $2 $3 --region $4 -f value -c id)
|
||||||
--adminurl $4 \
|
|
||||||
--internalurl $5 \
|
|
||||||
| grep " id " | get_field 2)
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo $endpoint_id
|
echo $endpoint_id
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Gets or creates endpoint
|
||||||
|
# Usage: get_or_create_endpoint <service> <region> <publicurl> <adminurl> <internalurl>
|
||||||
|
function get_or_create_endpoint {
|
||||||
|
# NOTE(jamielennnox): when converting to v3 endpoint creation we go from
|
||||||
|
# creating one endpoint with multiple urls to multiple endpoints each with
|
||||||
|
# a different interface. To maintain the existing function interface we
|
||||||
|
# create 3 endpoints and return the id of the public one. In reality
|
||||||
|
# returning the public id will not make a lot of difference as there are no
|
||||||
|
# scenarios currently that use the returned id. Ideally this behaviour
|
||||||
|
# should be pushed out to the service setups and let them create the
|
||||||
|
# endpoints they need.
|
||||||
|
local public_id=$(_get_or_create_endpoint_with_interface $1 public $3 $2)
|
||||||
|
_get_or_create_endpoint_with_interface $1 admin $4 $2
|
||||||
|
_get_or_create_endpoint_with_interface $1 internal $5 $2
|
||||||
|
|
||||||
|
# return the public id to indicate success, and this is the endpoint most likely wanted
|
||||||
|
echo $public_id
|
||||||
|
}
|
||||||
|
|
||||||
|
# Get a URL from the identity service
|
||||||
|
# Usage: get_endpoint_url <service> <interface>
|
||||||
|
function get_endpoint_url {
|
||||||
|
echo $(openstack endpoint list \
|
||||||
|
--service $1 --interface $2 \
|
||||||
|
--os-url $KEYSTONE_SERVICE_URI_V3 \
|
||||||
|
--os-identity-api-version=3 \
|
||||||
|
-c URL -f value)
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
# Package Functions
|
# Package Functions
|
||||||
# =================
|
# =================
|
||||||
|
@ -130,9 +130,8 @@ function create_ceilometer_accounts {
|
|||||||
create_service_user "ceilometer" "admin"
|
create_service_user "ceilometer" "admin"
|
||||||
|
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
local ceilometer_service=$(get_or_create_service "ceilometer" \
|
get_or_create_service "ceilometer" "metering" "OpenStack Telemetry Service"
|
||||||
"metering" "OpenStack Telemetry Service")
|
get_or_create_endpoint "metering" \
|
||||||
get_or_create_endpoint $ceilometer_service \
|
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$CEILOMETER_SERVICE_PROTOCOL://$CEILOMETER_SERVICE_HOST:$CEILOMETER_SERVICE_PORT/" \
|
"$CEILOMETER_SERVICE_PROTOCOL://$CEILOMETER_SERVICE_HOST:$CEILOMETER_SERVICE_PORT/" \
|
||||||
"$CEILOMETER_SERVICE_PROTOCOL://$CEILOMETER_SERVICE_HOST:$CEILOMETER_SERVICE_PORT/" \
|
"$CEILOMETER_SERVICE_PROTOCOL://$CEILOMETER_SERVICE_HOST:$CEILOMETER_SERVICE_PORT/" \
|
||||||
|
10
lib/cinder
10
lib/cinder
@ -329,16 +329,14 @@ function create_cinder_accounts {
|
|||||||
|
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
|
||||||
local cinder_service=$(get_or_create_service "cinder" \
|
get_or_create_service "cinder" "volume" "Cinder Volume Service"
|
||||||
"volume" "Cinder Volume Service")
|
get_or_create_endpoint "volume" "$REGION_NAME" \
|
||||||
get_or_create_endpoint $cinder_service "$REGION_NAME" \
|
|
||||||
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v1/\$(tenant_id)s" \
|
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v1/\$(tenant_id)s" \
|
||||||
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v1/\$(tenant_id)s" \
|
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v1/\$(tenant_id)s" \
|
||||||
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v1/\$(tenant_id)s"
|
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v1/\$(tenant_id)s"
|
||||||
|
|
||||||
local cinder_v2_service=$(get_or_create_service "cinderv2" \
|
get_or_create_service "cinderv2" "volumev2" "Cinder Volume Service V2"
|
||||||
"volumev2" "Cinder Volume Service V2")
|
get_or_create_endpoint "volumev2" "$REGION_NAME" \
|
||||||
get_or_create_endpoint $cinder_v2_service "$REGION_NAME" \
|
|
||||||
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v2/\$(tenant_id)s" \
|
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v2/\$(tenant_id)s" \
|
||||||
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v2/\$(tenant_id)s" \
|
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v2/\$(tenant_id)s" \
|
||||||
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v2/\$(tenant_id)s"
|
"$CINDER_SERVICE_PROTOCOL://$CINDER_SERVICE_HOST:$CINDER_SERVICE_PORT/v2/\$(tenant_id)s"
|
||||||
|
10
lib/glance
10
lib/glance
@ -272,9 +272,8 @@ function create_glance_accounts {
|
|||||||
|
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
|
||||||
local glance_service=$(get_or_create_service "glance" \
|
get_or_create_service "glance" "image" "Glance Image Service"
|
||||||
"image" "Glance Image Service")
|
get_or_create_endpoint "image" \
|
||||||
get_or_create_endpoint $glance_service \
|
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$GLANCE_SERVICE_PROTOCOL://$GLANCE_HOSTPORT" \
|
"$GLANCE_SERVICE_PROTOCOL://$GLANCE_HOSTPORT" \
|
||||||
"$GLANCE_SERVICE_PROTOCOL://$GLANCE_HOSTPORT" \
|
"$GLANCE_SERVICE_PROTOCOL://$GLANCE_HOSTPORT" \
|
||||||
@ -285,10 +284,9 @@ function create_glance_accounts {
|
|||||||
# Add glance-search service and endpoints
|
# Add glance-search service and endpoints
|
||||||
if is_service_enabled g-search; then
|
if is_service_enabled g-search; then
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
local glance_search_service=$(get_or_create_service "glance-search" \
|
get_or_create_service "glance-search" "search" "EXPERIMENTAL - Glance Graffiti Search Service"
|
||||||
"search" "EXPERIMENTAL - Glance Graffiti Search Service")
|
|
||||||
|
|
||||||
get_or_create_endpoint $glance_search_service \
|
get_or_create_endpoint "search" \
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$GLANCE_SERVICE_PROTOCOL://$GLANCE_SEARCH_HOSTPORT" \
|
"$GLANCE_SERVICE_PROTOCOL://$GLANCE_SEARCH_HOSTPORT" \
|
||||||
"$GLANCE_SERVICE_PROTOCOL://$GLANCE_SEARCH_HOSTPORT" \
|
"$GLANCE_SERVICE_PROTOCOL://$GLANCE_SEARCH_HOSTPORT" \
|
||||||
|
10
lib/heat
10
lib/heat
@ -250,17 +250,15 @@ function create_heat_accounts {
|
|||||||
|
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
|
||||||
local heat_service=$(get_or_create_service "heat" \
|
get_or_create_service "heat" "orchestration" "Heat Orchestration Service"
|
||||||
"orchestration" "Heat Orchestration Service")
|
get_or_create_endpoint "orchestration" \
|
||||||
get_or_create_endpoint $heat_service \
|
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$SERVICE_PROTOCOL://$HEAT_API_HOST:$HEAT_API_PORT/v1/\$(tenant_id)s" \
|
"$SERVICE_PROTOCOL://$HEAT_API_HOST:$HEAT_API_PORT/v1/\$(tenant_id)s" \
|
||||||
"$SERVICE_PROTOCOL://$HEAT_API_HOST:$HEAT_API_PORT/v1/\$(tenant_id)s" \
|
"$SERVICE_PROTOCOL://$HEAT_API_HOST:$HEAT_API_PORT/v1/\$(tenant_id)s" \
|
||||||
"$SERVICE_PROTOCOL://$HEAT_API_HOST:$HEAT_API_PORT/v1/\$(tenant_id)s"
|
"$SERVICE_PROTOCOL://$HEAT_API_HOST:$HEAT_API_PORT/v1/\$(tenant_id)s"
|
||||||
|
|
||||||
local heat_cfn_service=$(get_or_create_service "heat-cfn" \
|
get_or_create_service "heat-cfn" "cloudformation" "Heat CloudFormation Service"
|
||||||
"cloudformation" "Heat CloudFormation Service")
|
get_or_create_endpoint "cloudformation" \
|
||||||
get_or_create_endpoint $heat_cfn_service \
|
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$SERVICE_PROTOCOL://$HEAT_API_CFN_HOST:$HEAT_API_CFN_PORT/v1" \
|
"$SERVICE_PROTOCOL://$HEAT_API_CFN_HOST:$HEAT_API_CFN_PORT/v1" \
|
||||||
"$SERVICE_PROTOCOL://$HEAT_API_CFN_HOST:$HEAT_API_CFN_PORT/v1" \
|
"$SERVICE_PROTOCOL://$HEAT_API_CFN_HOST:$HEAT_API_CFN_PORT/v1" \
|
||||||
|
@ -411,9 +411,8 @@ function create_ironic_accounts {
|
|||||||
|
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
|
||||||
local ironic_service=$(get_or_create_service "ironic" \
|
get_or_create_service "ironic" "baremetal" "Ironic baremetal provisioning service"
|
||||||
"baremetal" "Ironic baremetal provisioning service")
|
get_or_create_endpoint "baremetal" \
|
||||||
get_or_create_endpoint $ironic_service \
|
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$IRONIC_SERVICE_PROTOCOL://$IRONIC_HOSTPORT" \
|
"$IRONIC_SERVICE_PROTOCOL://$IRONIC_HOSTPORT" \
|
||||||
"$IRONIC_SERVICE_PROTOCOL://$IRONIC_HOSTPORT" \
|
"$IRONIC_SERVICE_PROTOCOL://$IRONIC_HOSTPORT" \
|
||||||
|
@ -406,9 +406,8 @@ function create_keystone_accounts {
|
|||||||
# Keystone
|
# Keystone
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
|
||||||
KEYSTONE_SERVICE=$(get_or_create_service "keystone" \
|
get_or_create_service "keystone" "identity" "Keystone Identity Service"
|
||||||
"identity" "Keystone Identity Service")
|
get_or_create_endpoint "identity" \
|
||||||
get_or_create_endpoint $KEYSTONE_SERVICE \
|
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$KEYSTONE_SERVICE_PROTOCOL://$KEYSTONE_SERVICE_HOST:$KEYSTONE_SERVICE_PORT/v$IDENTITY_API_VERSION" \
|
"$KEYSTONE_SERVICE_PROTOCOL://$KEYSTONE_SERVICE_HOST:$KEYSTONE_SERVICE_PORT/v$IDENTITY_API_VERSION" \
|
||||||
"$KEYSTONE_AUTH_PROTOCOL://$KEYSTONE_AUTH_HOST:$KEYSTONE_AUTH_PORT/v$IDENTITY_API_VERSION" \
|
"$KEYSTONE_AUTH_PROTOCOL://$KEYSTONE_AUTH_HOST:$KEYSTONE_AUTH_PORT/v$IDENTITY_API_VERSION" \
|
||||||
|
@ -519,9 +519,8 @@ function create_neutron_accounts {
|
|||||||
|
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
|
||||||
local neutron_service=$(get_or_create_service "neutron" \
|
get_or_create_service "neutron" "network" "Neutron Service"
|
||||||
"network" "Neutron Service")
|
get_or_create_endpoint "network" \
|
||||||
get_or_create_endpoint $neutron_service \
|
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$Q_PROTOCOL://$SERVICE_HOST:$Q_PORT/" \
|
"$Q_PROTOCOL://$SERVICE_HOST:$Q_PORT/" \
|
||||||
"$Q_PROTOCOL://$SERVICE_HOST:$Q_PORT/" \
|
"$Q_PROTOCOL://$SERVICE_HOST:$Q_PORT/" \
|
||||||
|
21
lib/nova
21
lib/nova
@ -404,24 +404,22 @@ function create_nova_accounts {
|
|||||||
create_service_user "nova" "admin"
|
create_service_user "nova" "admin"
|
||||||
|
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
|
||||||
local nova_service=$(get_or_create_service "nova" \
|
|
||||||
"compute" "Nova Compute Service")
|
|
||||||
local nova_api_url
|
local nova_api_url
|
||||||
if [[ "$NOVA_USE_MOD_WSGI" == "False" ]]; then
|
if [[ "$NOVA_USE_MOD_WSGI" == "False" ]]; then
|
||||||
nova_api_url="$NOVA_SERVICE_PROTOCOL://$NOVA_SERVICE_HOST:$NOVA_SERVICE_PORT"
|
nova_api_url="$NOVA_SERVICE_PROTOCOL://$NOVA_SERVICE_HOST:$NOVA_SERVICE_PORT"
|
||||||
else
|
else
|
||||||
nova_api_url="$NOVA_SERVICE_PROTOCOL://$NOVA_SERVICE_HOST/compute"
|
nova_api_url="$NOVA_SERVICE_PROTOCOL://$NOVA_SERVICE_HOST/compute"
|
||||||
fi
|
fi
|
||||||
get_or_create_endpoint $nova_service \
|
|
||||||
|
get_or_create_service "nova" "compute" "Nova Compute Service"
|
||||||
|
get_or_create_endpoint "compute" \
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$nova_api_url/v2/\$(tenant_id)s" \
|
"$nova_api_url/v2/\$(tenant_id)s" \
|
||||||
"$nova_api_url/v2/\$(tenant_id)s" \
|
"$nova_api_url/v2/\$(tenant_id)s" \
|
||||||
"$nova_api_url/v2/\$(tenant_id)s"
|
"$nova_api_url/v2/\$(tenant_id)s"
|
||||||
|
|
||||||
local nova_v21_service=$(get_or_create_service "novav21" \
|
get_or_create_service "novav21" "computev21" "Nova Compute Service V2.1"
|
||||||
"computev21" "Nova Compute Service V2.1")
|
get_or_create_endpoint "computev21" \
|
||||||
get_or_create_endpoint $nova_v21_service \
|
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$nova_api_url/v2.1/\$(tenant_id)s" \
|
"$nova_api_url/v2.1/\$(tenant_id)s" \
|
||||||
"$nova_api_url/v2.1/\$(tenant_id)s" \
|
"$nova_api_url/v2.1/\$(tenant_id)s" \
|
||||||
@ -440,9 +438,8 @@ function create_nova_accounts {
|
|||||||
# EC2
|
# EC2
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = "sql" ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = "sql" ]]; then
|
||||||
|
|
||||||
local ec2_service=$(get_or_create_service "ec2" \
|
get_or_create_service "ec2" "ec2" "EC2 Compatibility Layer"
|
||||||
"ec2" "EC2 Compatibility Layer")
|
get_or_create_endpoint "ec2" \
|
||||||
get_or_create_endpoint $ec2_service \
|
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$EC2_SERVICE_PROTOCOL://$SERVICE_HOST:8773/" \
|
"$EC2_SERVICE_PROTOCOL://$SERVICE_HOST:8773/" \
|
||||||
"$EC2_SERVICE_PROTOCOL://$SERVICE_HOST:8773/" \
|
"$EC2_SERVICE_PROTOCOL://$SERVICE_HOST:8773/" \
|
||||||
@ -454,8 +451,8 @@ function create_nova_accounts {
|
|||||||
if is_service_enabled n-obj swift3; then
|
if is_service_enabled n-obj swift3; then
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
|
||||||
local s3_service=$(get_or_create_service "s3" "s3" "S3")
|
get_or_create_service "s3" "s3" "S3"
|
||||||
get_or_create_endpoint $s3_service \
|
get_or_create_endpoint "s3" \
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"http://$SERVICE_HOST:$S3_SERVICE_PORT" \
|
"http://$SERVICE_HOST:$S3_SERVICE_PORT" \
|
||||||
"http://$SERVICE_HOST:$S3_SERVICE_PORT" \
|
"http://$SERVICE_HOST:$S3_SERVICE_PORT" \
|
||||||
|
@ -608,9 +608,8 @@ function create_swift_accounts {
|
|||||||
|
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
|
||||||
local swift_service=$(get_or_create_service "swift" \
|
get_or_create_service "swift" "object-store" "Swift Service"
|
||||||
"object-store" "Swift Service")
|
get_or_create_endpoint "object-store" \
|
||||||
get_or_create_endpoint $swift_service \
|
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$SWIFT_SERVICE_PROTOCOL://$SERVICE_HOST:8080/v1/AUTH_\$(tenant_id)s" \
|
"$SWIFT_SERVICE_PROTOCOL://$SERVICE_HOST:8080/v1/AUTH_\$(tenant_id)s" \
|
||||||
"$SWIFT_SERVICE_PROTOCOL://$SERVICE_HOST:8080" \
|
"$SWIFT_SERVICE_PROTOCOL://$SERVICE_HOST:8080" \
|
||||||
|
@ -270,11 +270,11 @@ function configure_tempest {
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
EC2_URL=$(openstack endpoint show -f value -c publicurl ec2 || true)
|
EC2_URL=$(get_endpoint_url ec2 public || true)
|
||||||
if [[ -z $EC2_URL ]]; then
|
if [[ -z $EC2_URL ]]; then
|
||||||
EC2_URL="$EC2_SERVICE_PROTOCOL://$SERVICE_HOST:8773/"
|
EC2_URL="$EC2_SERVICE_PROTOCOL://$SERVICE_HOST:8773/"
|
||||||
fi
|
fi
|
||||||
S3_URL=$(openstack endpoint show -f value -c publicurl s3 || true)
|
S3_URL=$(get_endpoint_url s3 public || true)
|
||||||
if [[ -z $S3_URL ]]; then
|
if [[ -z $S3_URL ]]; then
|
||||||
S3_URL="http://$SERVICE_HOST:${S3_SERVICE_PORT:-3333}"
|
S3_URL="http://$SERVICE_HOST:${S3_SERVICE_PORT:-3333}"
|
||||||
fi
|
fi
|
||||||
|
@ -210,9 +210,8 @@ function create_zaqar_accounts {
|
|||||||
|
|
||||||
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
|
||||||
|
|
||||||
local zaqar_service=$(get_or_create_service "zaqar" \
|
get_or_create_service "zaqar" "messaging" "Zaqar Service"
|
||||||
"messaging" "Zaqar Service")
|
get_or_create_endpoint "messaging" \
|
||||||
get_or_create_endpoint $zaqar_service \
|
|
||||||
"$REGION_NAME" \
|
"$REGION_NAME" \
|
||||||
"$ZAQAR_SERVICE_PROTOCOL://$ZAQAR_SERVICE_HOST:$ZAQAR_SERVICE_PORT" \
|
"$ZAQAR_SERVICE_PROTOCOL://$ZAQAR_SERVICE_HOST:$ZAQAR_SERVICE_PORT" \
|
||||||
"$ZAQAR_SERVICE_PROTOCOL://$ZAQAR_SERVICE_HOST:$ZAQAR_SERVICE_PORT" \
|
"$ZAQAR_SERVICE_PROTOCOL://$ZAQAR_SERVICE_HOST:$ZAQAR_SERVICE_PORT" \
|
||||||
|
Loading…
Reference in New Issue
Block a user