Support a flag for setting Keystone Token backend

Fixes LP# 1073274

Change-Id: Ib4373a4a4d31e440e40f977f8f7ffa312f2d97be
This commit is contained in:
Davanum Srinivas 2013-01-29 15:12:20 -05:00
parent 95fb0d440c
commit 5bd96f967f

View File

@ -39,6 +39,9 @@ KEYSTONECLIENT_DIR=$DEST/python-keystoneclient
KEYSTONE_CATALOG_BACKEND=${KEYSTONE_CATALOG_BACKEND:-sql}
KEYSTONE_CATALOG=$KEYSTONE_CONF_DIR/default_catalog.templates
# Select the backend for Tokens
KEYSTONE_TOKEN_BACKEND=${KEYSTONE_TOKEN_BACKEND:-sql}
# Select Keystone's token format
# Choose from 'UUID' and 'PKI'
KEYSTONE_TOKEN_FORMAT=${KEYSTONE_TOKEN_FORMAT:-PKI}
@ -108,6 +111,12 @@ function configure_keystone() {
# Append the S3 bits
iniset $KEYSTONE_CONF filter:s3_extension paste.filter_factory "keystone.contrib.s3:S3Extension.factory"
if [[ "$KEYSTONE_TOKEN_BACKEND" = "sql" ]]; then
iniset $KEYSTONE_CONF token driver keystone.token.backends.sql.Token
else
iniset $KEYSTONE_CONF token driver keystone.token.backends.kvs.Token
fi
if [[ "$KEYSTONE_CATALOG_BACKEND" = "sql" ]]; then
# Configure ``keystone.conf`` to use sql
iniset $KEYSTONE_CONF catalog driver keystone.catalog.backends.sql.Catalog