diff --git a/doc/source/developing.rst b/doc/source/developing.rst index 389a268490..50fed9e53a 100644 --- a/doc/source/developing.rst +++ b/doc/source/developing.rst @@ -159,7 +159,7 @@ data for use with keystone: .. code-block:: bash - $ OS_SERVICE_TOKEN=ADMIN tools/with_venv.sh tools/sample_data.sh + $ OS_TOKEN=ADMIN tools/with_venv.sh tools/sample_data.sh Notice it requires a service token read from an environment variable for authentication. The default value "ADMIN" is from the ``admin_token`` diff --git a/tools/sample_data.sh b/tools/sample_data.sh index f8b1d6aca1..4646b40ee3 100755 --- a/tools/sample_data.sh +++ b/tools/sample_data.sh @@ -19,9 +19,9 @@ # This script is based on the original DevStack keystone_data.sh script. # # It demonstrates how to bootstrap Keystone with an administrative user -# using the OS_SERVICE_TOKEN and OS_SERVICE_ENDPOINT environment variables -# and the administrative API. It will get the admin_token (OS_SERVICE_TOKEN) -# and admin_port from keystone.conf if available. +# using the OS_TOKEN and OS_URL environment variables and the administrative +# API. It will get the admin_token (OS_TOKEN) and admin_port from +# keystone.conf if available. # # Disable creation of endpoints by setting DISABLE_ENDPOINTS environment variable. # Use this with the Catalog Templated backend. @@ -85,14 +85,14 @@ if [[ -r "$KEYSTONE_CONF" ]]; then fi fi -export OS_SERVICE_TOKEN=${OS_SERVICE_TOKEN:-$CONFIG_SERVICE_TOKEN} -if [[ -z "$OS_SERVICE_TOKEN" ]]; then +export OS_TOKEN=${OS_TOKEN:-$CONFIG_SERVICE_TOKEN} +if [[ -z "$OS_TOKEN" ]]; then echo "No service token found." - echo "Set OS_SERVICE_TOKEN manually from keystone.conf admin_token." + echo "Set OS_TOKEN manually from keystone.conf admin_token." exit 1 fi -export OS_SERVICE_ENDPOINT=${OS_SERVICE_ENDPOINT:-http://$CONTROLLER_PUBLIC_ADDRESS:${CONFIG_ADMIN_PORT:-35357}/v2.0} +export OS_URL=${OS_URL:-http://$CONTROLLER_PUBLIC_ADDRESS:${CONFIG_ADMIN_PORT:-35357}/v2.0} function get_id () { echo `"$@" | grep ' id ' | awk '{print $4}'`