Merge "Setup PKI for Keystone"
diff --git a/README.md b/README.md
index cfcfe7c..b860afd 100644
--- a/README.md
+++ b/README.md
@@ -69,7 +69,7 @@
If you use Swift with Keystone, Swift will authenticate against it. You will need to make sure to use the Keystone URL to auth against.
-Swift will be acting as a S3 endpoint for Keystone so effectively replacing the `nova-objectstore`.
+If you are enabling `swift3` in `ENABLED_SERVICES` devstack will install the swift3 middleware emulation. Swift will be configured to act as a S3 endpoint for Keystone so effectively replacing the `nova-objectstore`.
Only Swift proxy server is launched in the screen session all other services are started in background and managed by `swift-init` tool.
diff --git a/exercises/bundle.sh b/exercises/bundle.sh
index c607c94..daff5f9 100755
--- a/exercises/bundle.sh
+++ b/exercises/bundle.sh
@@ -17,6 +17,7 @@
# an error. It is also useful for following allowing as the install occurs.
set -o xtrace
+
# Settings
# ========
diff --git a/exercises/client-args.sh b/exercises/client-args.sh
index 1d7d5b6..7229ecf 100755
--- a/exercises/client-args.sh
+++ b/exercises/client-args.sh
@@ -1,11 +1,14 @@
#!/usr/bin/env bash
+**client-args.sh**
+
# Test OpenStack client authentication aguemnts handling
echo "*********************************************************************"
echo "Begin DevStack Exercise: $0"
echo "*********************************************************************"
+
# Settings
# ========
@@ -38,7 +41,7 @@
export x_PASSWORD=$OS_PASSWORD
export x_AUTH_URL=$OS_AUTH_URL
-#Unset the usual variables to force argument processing
+# Unset the usual variables to force argument processing
unset OS_TENANT_NAME
unset OS_USERNAME
unset OS_PASSWORD
diff --git a/exercises/client-env.sh b/exercises/client-env.sh
index 10871a6..d242ee5 100755
--- a/exercises/client-env.sh
+++ b/exercises/client-env.sh
@@ -1,13 +1,13 @@
#!/usr/bin/env bash
+**client-env.sh**
+
# Test OpenStack client enviroment variable handling
echo "*********************************************************************"
echo "Begin DevStack Exercise: $0"
echo "*********************************************************************"
-# Verify client workage
-VERIFY=${1:-""}
# Settings
# ========
diff --git a/exercises/floating_ips.sh b/exercises/floating_ips.sh
index 82f29eb..51019a3 100755
--- a/exercises/floating_ips.sh
+++ b/exercises/floating_ips.sh
@@ -83,7 +83,7 @@
fi
fi
-# determinine instance type
+# Determinine instance type
# -------------------------
# List of instance types:
@@ -100,6 +100,7 @@
VM_UUID=`nova boot --flavor $INSTANCE_TYPE --image $IMAGE $NAME --security_groups=$SECGROUP | grep ' id ' | get_field 2`
die_if_not_set VM_UUID "Failure launching $NAME"
+
# Testing
# =======
diff --git a/exercises/swift.sh b/exercises/swift.sh
index 732445d..4cd487b 100755
--- a/exercises/swift.sh
+++ b/exercises/swift.sh
@@ -40,6 +40,7 @@
# exercise is skipped.
is_service_enabled swift || exit 55
+
# Testing Swift
# =============
diff --git a/files/keystone_data.sh b/files/keystone_data.sh
index 7886072..ba14a47 100755
--- a/files/keystone_data.sh
+++ b/files/keystone_data.sh
@@ -283,4 +283,16 @@
keystone user-role-add --tenant_id $SERVICE_TENANT \
--user_id $CINDER_USER \
--role_id $ADMIN_ROLE
+ if [[ "$KEYSTONE_CATALOG_BACKEND" = 'sql' ]]; then
+ CINDER_SERVICE=$(get_id keystone service-create \
+ --name=cinder \
+ --type=volume \
+ --description="Cinder Service")
+ keystone endpoint-create \
+ --region RegionOne \
+ --service_id $CINDER_SERVICE \
+ --publicurl "http://$SERVICE_HOST:8776/v1/\$(tenant_id)s" \
+ --adminurl "http://$SERVICE_HOST:8776/v1/\$(tenant_id)s" \
+ --internalurl "http://$SERVICE_HOST:8776/v1/\$(tenant_id)s"
+ fi
fi
diff --git a/stack.sh b/stack.sh
index b21989b..8886045 100755
--- a/stack.sh
+++ b/stack.sh
@@ -168,14 +168,12 @@
# ability to run sudo
if [[ "$os_PACKAGE" = "deb" ]]; then
dpkg -l sudo || apt_get update && install_package sudo
- STACK_GROUP=sudo
else
rpm -qa | grep sudo || install_package sudo
- STACK_GROUP=wheel
fi
if ! getent passwd stack >/dev/null; then
echo "Creating a user called stack"
- useradd -U -G $STACK_GROUP -s /bin/bash -d $DEST -m stack
+ useradd -U -s /bin/bash -d $DEST -m stack
fi
echo "Giving stack user passwordless sudo priviledges"
@@ -247,7 +245,6 @@
# Get project function libraries
source $TOP_DIR/lib/cinder
-
# Set the destination directories for openstack projects
NOVA_DIR=$DEST/nova
HORIZON_DIR=$DEST/horizon
@@ -298,7 +295,7 @@
HOST_IP_IFACE=${HOST_IP_IFACE:-eth0}
# Use the eth0 IP unless an explicit is set by ``HOST_IP`` environment variable
if [ -z "$HOST_IP" -o "$HOST_IP" == "dhcp" ]; then
- HOST_IP=`LC_ALL=C /sbin/ifconfig ${HOST_IP_IFACE} | grep -m 1 'inet addr:'| cut -d: -f2 | awk '{print $1}'`
+ HOST_IP=`LC_ALL=C ip -f inet addr show ${HOST_IP_IFACE} | awk '/inet/ {split($2,parts,"/"); print parts[1]}' | head -n1`
if [ "$HOST_IP" = "" ]; then
echo "Could not determine host ip address."
echo "Either localrc specified dhcp on ${HOST_IP_IFACE} or defaulted to eth0"
@@ -465,9 +462,9 @@
GLANCE_HOSTPORT=${GLANCE_HOSTPORT:-$SERVICE_HOST:9292}
-# SWIFT
+# Swift
# -----
-# TODO: implement glance support
+
# TODO: add logging to different location.
# By default the location of swift drives and objects is located inside
@@ -479,7 +476,7 @@
# directory, change SWIFT_CONFIG_DIR if you want to adjust that.
SWIFT_CONFIG_DIR=${SWIFT_CONFIG_DIR:-/etc/swift}
-# devstack will create a loop-back disk formatted as XFS to store the
+# DevStack will create a loop-back disk formatted as XFS to store the
# swift data. By default the disk size is 1 gigabyte. The variable
# SWIFT_LOOPBACK_DISK_SIZE specified in bytes allow you to change
# that.
@@ -502,9 +499,11 @@
SWIFT_REPLICAS=${SWIFT_REPLICAS:-3}
if is_service_enabled swift; then
- # If we are using swift, we can default the s3 port to swift instead
+ # If we are using swift3, we can default the s3 port to swift instead
# of nova-objectstore
- S3_SERVICE_PORT=${S3_SERVICE_PORT:-8080}
+ if is_service_enabled swift3;then
+ S3_SERVICE_PORT=${S3_SERVICE_PORT:-8080}
+ fi
# We only ask for Swift Hash if we have enabled swift service.
# SWIFT_HASH is a random unique string for a swift cluster that
# can never change.
@@ -514,6 +513,7 @@
# Set default port for nova-objectstore
S3_SERVICE_PORT=${S3_SERVICE_PORT:-3333}
+
# Keystone
# --------
@@ -611,10 +611,10 @@
# Install Packages
# ================
-#
+
# Openstack uses a fair number of other projects.
-# install package requirements
+# Install package requirements
if [[ "$os_PACKAGE" = "deb" ]]; then
apt_get update
install_package $(get_packages $FILES/apts)
@@ -622,12 +622,13 @@
install_package $(get_packages $FILES/rpms)
fi
-# install python requirements
+# Install python requirements
pip_install $(get_packages $FILES/pips | sort -u)
-# compute service
+# Check out OpenStack sources
git_clone $NOVA_REPO $NOVA_DIR $NOVA_BRANCH
-# python client library to nova that horizon (and others) use
+
+# Check out the client libs that are used most
git_clone $KEYSTONECLIENT_REPO $KEYSTONECLIENT_DIR $KEYSTONECLIENT_BRANCH
git_clone $NOVACLIENT_REPO $NOVACLIENT_DIR $NOVACLIENT_BRANCH
git_clone $OPENSTACKCLIENT_REPO $OPENSTACKCLIENT_DIR $OPENSTACKCLIENT_BRANCH
@@ -643,8 +644,10 @@
git_clone $SWIFT_REPO $SWIFT_DIR $SWIFT_BRANCH
# storage service client and and Library
git_clone $SWIFTCLIENT_REPO $SWIFTCLIENT_DIR $SWIFTCLIENT_BRANCH
- # swift3 middleware to provide S3 emulation to Swift
- git_clone $SWIFT3_REPO $SWIFT3_DIR $SWIFT3_BRANCH
+ if is_service_enabled swift3; then
+ # swift3 middleware to provide S3 emulation to Swift
+ git_clone $SWIFT3_REPO $SWIFT3_DIR $SWIFT3_BRANCH
+ fi
fi
if is_service_enabled g-api n-api; then
# image catalog service
@@ -680,7 +683,7 @@
# Initialization
# ==============
-# setup our checkouts so they are installed into python path
+# Set up our checkouts so they are installed into python path
# allowing ``import nova`` or ``import glance.client``
setup_develop $KEYSTONECLIENT_DIR
setup_develop $NOVACLIENT_DIR
@@ -820,7 +823,7 @@
sudo sed -i '/^bind-address/s/127.0.0.1/0.0.0.0/g' $MY_CONF
# Set default db type to InnoDB
- if grep -q "default-storage-engine" $MY_CONF; then
+ if sudo grep -q "default-storage-engine" $MY_CONF; then
# Change it
sudo bash -c "source $TOP_DIR/functions; iniset $MY_CONF mysqld default-storage-engine InnoDB"
else
@@ -876,16 +879,17 @@
fi
}
-# create a new named screen to run processes in
+# Create a new named screen to run processes in
screen -d -m -S stack -t stack -s /bin/bash
sleep 1
-# set a reasonable statusbar
+# Set a reasonable statusbar
screen -r stack -X hardstatus alwayslastline "$SCREEN_HARDSTATUS"
+
# Horizon
# -------
-# Setup the django horizon application to serve via apache/wsgi
+# Set up the django horizon application to serve via apache/wsgi
if is_service_enabled horizon; then
@@ -899,10 +903,10 @@
# Initialize the horizon database (it stores sessions and notices shown to
# users). The user system is external (keystone).
cd $HORIZON_DIR
- python manage.py syncdb
+ python manage.py syncdb --noinput
cd $TOP_DIR
- # create an empty directory that apache uses as docroot
+ # Create an empty directory that apache uses as docroot
sudo mkdir -p $HORIZON_DIR/.blackhole
if [[ "$os_PACKAGE" = "deb" ]]; then
@@ -1009,8 +1013,10 @@
fi
-# Quantum (for controller or agent nodes)
+
+# Quantum
# -------
+
if is_service_enabled quantum; then
# Put config files in /etc/quantum for everyone to find
if [[ ! -d /etc/quantum ]]; then
@@ -1036,7 +1042,7 @@
exit 1
fi
- # if needed, move config file from $QUANTUM_DIR/etc/quantum to /etc/quantum
+ # If needed, move config file from $QUANTUM_DIR/etc/quantum to /etc/quantum
mkdir -p /$Q_PLUGIN_CONF_PATH
Q_PLUGIN_CONF_FILE=$Q_PLUGIN_CONF_PATH/$Q_PLUGIN_CONF_FILENAME
if [[ -e $QUANTUM_DIR/$Q_PLUGIN_CONF_FILE ]]; then
@@ -1145,7 +1151,6 @@
fi
-
# Nova
# ----
@@ -1281,7 +1286,7 @@
QEMU_CONF=/etc/libvirt/qemu.conf
if is_service_enabled quantum && [[ $Q_PLUGIN = "openvswitch" ]] && ! sudo grep -q '^cgroup_device_acl' $QEMU_CONF ; then
- # add /dev/net/tun to cgroup_device_acls, needed for type=ethernet interfaces
+ # Add /dev/net/tun to cgroup_device_acls, needed for type=ethernet interfaces
sudo chmod 666 $QEMU_CONF
sudo cat <<EOF >> /etc/libvirt/qemu.conf
cgroup_device_acl = [
@@ -1365,7 +1370,10 @@
sudo sysctl -w net.ipv4.ip_forward=1
fi
+
# Storage Service
+# ---------------
+
if is_service_enabled swift; then
# Install memcached for swift.
install_package memcached
@@ -1445,11 +1453,15 @@
sudo sed -i '/disable *= *yes/ { s/yes/no/ }' /etc/xinetd.d/rsync
fi
+ if is_service_enabled swift3;then
+ swift_auth_server="s3token "
+ fi
+
# By default Swift will be installed with the tempauth middleware
# which has some default username and password if you have
# configured keystone it will checkout the directory.
if is_service_enabled key; then
- swift_auth_server="s3token authtoken keystone"
+ swift_auth_server+="authtoken keystone"
else
swift_auth_server=tempauth
fi
@@ -1472,7 +1484,10 @@
iniuncomment ${SWIFT_CONFIG_PROXY_SERVER} DEFAULT bind_port
iniset ${SWIFT_CONFIG_PROXY_SERVER} DEFAULT bind_port ${SWIFT_DEFAULT_BIND_PORT:-8080}
- iniset ${SWIFT_CONFIG_PROXY_SERVER} pipeline:main pipeline "catch_errors healthcheck cache ratelimit swift3 ${swift_auth_server} proxy-logging proxy-server"
+ # Only enable Swift3 if we have it enabled in ENABLED_SERVICES
+ is_service_enabled swift3 && swift3=swift3 || swift3=""
+
+ iniset ${SWIFT_CONFIG_PROXY_SERVER} pipeline:main pipeline "catch_errors healthcheck cache ratelimit ${swift3} ${swift_auth_server} proxy-logging proxy-server"
iniset ${SWIFT_CONFIG_PROXY_SERVER} app:proxy-server account_autocreate true
@@ -1482,16 +1497,6 @@
paste.filter_factory = keystone.middleware.swift_auth:filter_factory
operator_roles = Member,admin
-# NOTE(chmou): s3token middleware is not updated yet to use only
-# username and password.
-[filter:s3token]
-paste.filter_factory = keystone.middleware.s3_token:filter_factory
-auth_port = ${KEYSTONE_AUTH_PORT}
-auth_host = ${KEYSTONE_AUTH_HOST}
-auth_protocol = ${KEYSTONE_AUTH_PROTOCOL}
-auth_token = ${SERVICE_TOKEN}
-admin_token = ${SERVICE_TOKEN}
-
[filter:authtoken]
paste.filter_factory = keystone.middleware.auth_token:filter_factory
auth_host = ${KEYSTONE_AUTH_HOST}
@@ -1501,10 +1506,23 @@
admin_tenant_name = ${SERVICE_TENANT_NAME}
admin_user = swift
admin_password = ${SERVICE_PASSWORD}
+EOF
+ if is_service_enabled swift3;then
+ cat <<EOF>>${SWIFT_CONFIG_PROXY_SERVER}
+# NOTE(chmou): s3token middleware is not updated yet to use only
+# username and password.
+[filter:s3token]
+paste.filter_factory = keystone.middleware.s3_token:filter_factory
+auth_port = ${KEYSTONE_AUTH_PORT}
+auth_host = ${KEYSTONE_AUTH_HOST}
+auth_protocol = ${KEYSTONE_AUTH_PROTOCOL}
+auth_token = ${SERVICE_TOKEN}
+admin_token = ${SERVICE_TOKEN}
[filter:swift3]
use = egg:swift3#swift3
EOF
+ fi
cp ${SWIFT_DIR}/etc/swift.conf-sample ${SWIFT_CONFIG_DIR}/swift.conf
iniset ${SWIFT_CONFIG_DIR}/swift.conf swift-hash swift_hash_path_suffix ${SWIFT_HASH}
@@ -1665,7 +1683,7 @@
echo "$1" >> $NOVA_CONF_DIR/$NOVA_CONF
}
-# remove legacy nova.conf
+# Remove legacy nova.conf
rm -f $NOVA_DIR/bin/nova.conf
# (re)create nova.conf
@@ -1722,6 +1740,7 @@
fi
add_nova_opt "sql_connection=$BASE_SQL_CONN/nova?charset=utf8"
add_nova_opt "libvirt_type=$LIBVIRT_TYPE"
+add_nova_opt "libvirt_cpu_mode=none"
add_nova_opt "instance_name_template=${INSTANCE_NAME_PREFIX}%08x"
# All nova-compute workers need to know the vnc configuration options
# These settings don't hurt anything if n-xvnc and n-novnc are disabled
@@ -1926,7 +1945,7 @@
iniset $KEYSTONE_CONF_DIR/logging.conf logger_root level "DEBUG"
iniset $KEYSTONE_CONF_DIR/logging.conf logger_root handlers "devel,production"
- # Set up the keystone database
+ # Initialize keystone database
$KEYSTONE_DIR/bin/keystone-manage db_sync
# set up certificates
$KEYSTONE_DIR/bin/keystone-manage pki_setup
@@ -1954,8 +1973,8 @@
export OS_USERNAME=admin
export OS_PASSWORD=$ADMIN_PASSWORD
- # create an access key and secret key for nova ec2 register image
- if is_service_enabled swift && is_service_enabled nova; then
+ # Create an access key and secret key for nova ec2 register image
+ if is_service_enabled swift3 && is_service_enabled nova; then
NOVA_USER_ID=$(keystone user-list | grep ' nova ' | get_field 1)
NOVA_TENANT_ID=$(keystone tenant-list | grep " $SERVICE_TENANT_NAME " | get_field 1)
CREDS=$(keystone ec2-credentials-create --user_id $NOVA_USER_ID --tenant_id $NOVA_TENANT_ID)
@@ -1967,7 +1986,7 @@
fi
fi
-# launch the nova-api and wait for it to answer before continuing
+# Launch the nova-api and wait for it to answer before continuing
if is_service_enabled n-api; then
add_nova_opt "enabled_apis=$NOVA_ENABLED_APIS"
screen_it n-api "cd $NOVA_DIR && $NOVA_DIR/bin/nova-api"
@@ -1981,13 +2000,13 @@
# If we're using Quantum (i.e. q-svc is enabled), network creation has to
# happen after we've started the Quantum service.
if is_service_enabled mysql && is_service_enabled nova; then
- # create a small network
+ # Create a small network
$NOVA_DIR/bin/nova-manage network create private $FIXED_RANGE 1 $FIXED_NETWORK_SIZE $NETWORK_CREATE_ARGS
- # create some floating ips
+ # Create some floating ips
$NOVA_DIR/bin/nova-manage floating create $FLOATING_RANGE
- # create a second pool
+ # Create a second pool
$NOVA_DIR/bin/nova-manage floating create --ip_range=$TEST_FLOATING_RANGE --pool=$TEST_FLOATING_POOL
fi
@@ -2011,11 +2030,12 @@
screen_it horizon "cd $HORIZON_DIR && sudo tail -f /var/log/$APACHE_NAME/horizon_error.log"
screen_it swift "cd $SWIFT_DIR && $SWIFT_DIR/bin/swift-proxy-server ${SWIFT_CONFIG_DIR}/proxy-server.conf -v"
-# Starting the nova-objectstore only if swift service is not enabled.
+# Starting the nova-objectstore only if swift3 service is not enabled.
# Swift will act as s3 objectstore.
-is_service_enabled swift || \
+is_service_enabled swift3 || \
screen_it n-obj "cd $NOVA_DIR && $NOVA_DIR/bin/nova-objectstore"
+
# Install Images
# ==============
diff --git a/tools/build_bm.sh b/tools/build_bm.sh
index 44cf303..b2d4c36 100755
--- a/tools/build_bm.sh
+++ b/tools/build_bm.sh
@@ -1,4 +1,7 @@
#!/usr/bin/env bash
+
+# **build_bm.sh**
+
# Build an OpenStack install on a bare metal machine.
set +x
diff --git a/tools/build_bm_multi.sh b/tools/build_bm_multi.sh
index 133d537..f1242ee 100755
--- a/tools/build_bm_multi.sh
+++ b/tools/build_bm_multi.sh
@@ -1,4 +1,7 @@
#!/usr/bin/env bash
+
+# **build_bm_multi.sh**
+
# Build an OpenStack install on several bare metal machines.
SHELL_AFTER_RUN=no
diff --git a/tools/build_pxe_env.sh b/tools/build_pxe_env.sh
index d01dad0..e6f98b4 100755
--- a/tools/build_pxe_env.sh
+++ b/tools/build_pxe_env.sh
@@ -1,5 +1,8 @@
#!/bin/bash -e
-# build_pxe_env.sh - Create a PXE boot environment
+
+# **build_pxe_env.sh**
+
+# Create a PXE boot environment
#
# build_pxe_env.sh destdir
#
diff --git a/tools/build_ramdisk.sh b/tools/build_ramdisk.sh
index 7c1600b..8e2c0be 100755
--- a/tools/build_ramdisk.sh
+++ b/tools/build_ramdisk.sh
@@ -1,7 +1,10 @@
#!/bin/bash
-# build_ramdisk.sh - Build RAM disk images
-# exit on error to stop unexpected errors
+# **build_ramdisk.sh**
+
+# Build RAM disk images
+
+# Exit on error to stop unexpected errors
set -o errexit
if [ ! "$#" -eq "1" ]; then
@@ -84,7 +87,7 @@
# Finds the next available NBD device
# Exits script if error connecting or none free
# map_nbd image
-# returns full nbd device path
+# Returns full nbd device path
function map_nbd {
for i in `seq 0 15`; do
if [ ! -e /sys/block/nbd$i/pid ]; then
@@ -105,7 +108,7 @@
echo $NBD
}
-# prime image with as many apt/pips as we can
+# Prime image with as many apt/pips as we can
DEV_FILE=$CACHEDIR/$DIST_NAME-dev.img
DEV_FILE_TMP=`mktemp $DEV_FILE.XXXXXX`
if [ ! -r $DEV_FILE ]; then
@@ -127,11 +130,11 @@
mkdir -p $MNTDIR/$DEST
chroot $MNTDIR chown stack $DEST
- # a simple password - pass
+ # A simple password - pass
echo stack:pass | chroot $MNTDIR chpasswd
echo root:$ROOT_PASSWORD | chroot $MNTDIR chpasswd
- # and has sudo ability (in the future this should be limited to only what
+ # And has sudo ability (in the future this should be limited to only what
# stack requires)
echo "stack ALL=(ALL) NOPASSWD: ALL" >> $MNTDIR/etc/sudoers
@@ -143,7 +146,8 @@
fi
rm -f $DEV_FILE_TMP
-# clone git repositories onto the system
+
+# Clone git repositories onto the system
# ======================================
IMG_FILE_TMP=`mktemp $IMG_FILE.XXXXXX`
diff --git a/tools/build_tempest.sh b/tools/build_tempest.sh
index 230e8f9..e72355c 100755
--- a/tools/build_tempest.sh
+++ b/tools/build_tempest.sh
@@ -1,7 +1,8 @@
#!/usr/bin/env bash
#
-# build_tempest.sh - Checkout and prepare a Tempest repo
-# (https://github.com/openstack/tempest.git)
+# **build_tempest.sh**
+
+# Checkout and prepare a Tempest repo: https://github.com/openstack/tempest.git
function usage {
echo "$0 - Check out and prepare a Tempest repo"
diff --git a/tools/build_uec.sh b/tools/build_uec.sh
index 35a4d6d..48819c9 100755
--- a/tools/build_uec.sh
+++ b/tools/build_uec.sh
@@ -1,5 +1,7 @@
#!/usr/bin/env bash
+# **build_uec.sh**
+
# Make sure that we have the proper version of ubuntu (only works on oneiric)
if ! egrep -q "oneiric" /etc/lsb-release; then
echo "This script only works with ubuntu oneiric."
diff --git a/tools/build_uec_ramdisk.sh b/tools/build_uec_ramdisk.sh
index 32f90c0..150ecab 100755
--- a/tools/build_uec_ramdisk.sh
+++ b/tools/build_uec_ramdisk.sh
@@ -1,7 +1,10 @@
#!/usr/bin/env bash
-# build_uec_ramdisk.sh - Build RAM disk images based on UEC image
-# exit on error to stop unexpected errors
+# **build_uec_ramdisk.sh**
+
+# Build RAM disk images based on UEC image
+
+# Exit on error to stop unexpected errors
set -o errexit
if [ ! "$#" -eq "1" ]; then
@@ -58,7 +61,7 @@
# Configure how large the VM should be
GUEST_SIZE=${GUEST_SIZE:-2G}
-# exit on error to stop unexpected errors
+# Exit on error to stop unexpected errors
set -o errexit
set -o xtrace
diff --git a/tools/build_usb_boot.sh b/tools/build_usb_boot.sh
index cca2a68..f64b7b6 100755
--- a/tools/build_usb_boot.sh
+++ b/tools/build_usb_boot.sh
@@ -1,5 +1,8 @@
#!/bin/bash -e
-# build_usb_boot.sh - Create a syslinux boot environment
+
+# **build_usb_boot.sh**
+
+# Create a syslinux boot environment
#
# build_usb_boot.sh destdev
#
diff --git a/tools/configure_tempest.sh b/tools/configure_tempest.sh
index 2c06934..bb995f8 100755
--- a/tools/configure_tempest.sh
+++ b/tools/configure_tempest.sh
@@ -1,6 +1,8 @@
#!/usr/bin/env bash
#
-# configure_tempest.sh - Build a tempest configuration file from devstack
+# **configure_tempest.sh**
+
+# Build a tempest configuration file from devstack
echo "**************************************************"
echo "Configuring Tempest"
@@ -162,9 +164,13 @@
s,%IMAGE_HOST%,$IMAGE_HOST,g;
s,%IMAGE_PORT%,$IMAGE_PORT,g;
s,%IMAGE_API_VERSION%,$IMAGE_API_VERSION,g;
- s,%ADMIN_USERNAME%,$ADMIN_USERNAME,g;
- s,%ADMIN_PASSWORD%,$ADMIN_PASSWORD,g;
- s,%ADMIN_TENANT_NAME%,$ADMIN_TENANT_NAME,g;
+ s,%COMPUTE_ADMIN_USERNAME%,$ADMIN_USERNAME,g;
+ s,%COMPUTE_ADMIN_PASSWORD%,$ADMIN_PASSWORD,g;
+ s,%COMPUTE_ADMIN_TENANT_NAME%,$ADMIN_TENANT_NAME,g;
+ s,%IDENTITY_ADMIN_USERNAME%,$ADMIN_USERNAME,g;
+ s,%IDENTITY_ADMIN_PASSWORD%,$ADMIN_PASSWORD,g;
+ s,%IDENTITY_ADMIN_TENANT_NAME%,$ADMIN_TENANT_NAME,g;
+ s,%COMPUTE_ALLOW_TENANT_ISOLATION%,true,g;
" -i $TEMPEST_CONF
echo "Created tempest configuration file:"
diff --git a/tools/copy_dev_environment_to_uec.sh b/tools/copy_dev_environment_to_uec.sh
index d5687dc..683a0d6 100755
--- a/tools/copy_dev_environment_to_uec.sh
+++ b/tools/copy_dev_environment_to_uec.sh
@@ -1,5 +1,7 @@
#!/usr/bin/env bash
+# **copy_dev_environment_to_uec.sh**
+
# Echo commands
set -o xtrace
diff --git a/tools/get_uec_image.sh b/tools/get_uec_image.sh
index 0963074..ca74a03 100755
--- a/tools/get_uec_image.sh
+++ b/tools/get_uec_image.sh
@@ -1,5 +1,8 @@
#!/bin/bash
-# get_uec_image.sh - Prepare Ubuntu UEC images
+
+# **get_uec_image.sh**
+
+# Download and prepare Ubuntu UEC images
CACHEDIR=${CACHEDIR:-/opt/stack/cache}
ROOTSIZE=${ROOTSIZE:-2000}
@@ -11,12 +14,12 @@
# Import common functions
. $TOP_DIR/functions
-# exit on error to stop unexpected errors
+# Exit on error to stop unexpected errors
set -o errexit
set -o xtrace
usage() {
- echo "Usage: $0 - Fetch and prepare Ubuntu images"
+ echo "Usage: $0 - Download and prepare Ubuntu UEC images"
echo ""
echo "$0 [-r rootsize] release imagefile [kernel]"
echo ""
diff --git a/tools/info.sh b/tools/info.sh
index edff617..bdca06e 100755
--- a/tools/info.sh
+++ b/tools/info.sh
@@ -1,5 +1,8 @@
#!/usr/bin/env bash
-# info.sh - Produce a report on the state of devstack installs
+
+# **info.sh**
+
+# Produce a report on the state of devstack installs
#
# Output fields are separated with '|' chars
# Output types are git,localrc,os,pip,pkg:
diff --git a/tools/install_openvpn.sh b/tools/install_openvpn.sh
index 44eee72..2f52aa1 100755
--- a/tools/install_openvpn.sh
+++ b/tools/install_openvpn.sh
@@ -1,5 +1,8 @@
#!/bin/bash
-# install_openvpn.sh - Install OpenVPN and generate required certificates
+
+# **install_openvpn.sh**
+
+# Install OpenVPN and generate required certificates
#
# install_openvpn.sh --client name
# install_openvpn.sh --server [name]
diff --git a/tools/warm_apts_and_pips_for_uec.sh b/tools/warm_apts_and_pips_for_uec.sh
index 23a28de..fe389ff 100755
--- a/tools/warm_apts_and_pips_for_uec.sh
+++ b/tools/warm_apts_and_pips_for_uec.sh
@@ -1,5 +1,7 @@
#!/usr/bin/env bash
+# **warm_apts_and_pips_for_uec.sh**
+
# Echo commands
set -o xtrace
diff --git a/unstack.sh b/unstack.sh
index 879f842..641d34e 100755
--- a/unstack.sh
+++ b/unstack.sh
@@ -1,5 +1,7 @@
#!/usr/bin/env bash
-#
+
+# **unstack.sh**
+
# Stops that which is started by ``stack.sh`` (mostly)
# mysql and rabbit are left running as OpenStack code refreshes
# do not require them to be restarted.