Files
training-labs/labs/osbash/scripts/ubuntu/setup_neutron_compute.sh
Roger Luethi 8ff32fa5a5 Mitaka updates
This changeset contains updates for Mitaka.

To build the basedisk (if necessary) and the cluster and launch a test VM
once:
./tools/repeat-test.sh -b -r 1

To test Orchestration:

./tools/test-once.sh scripts/test/heat_stack.sh

Change-Id: Idd96525c14abd5903a6631095ccd6797ba91365c
2016-04-09 09:23:49 +02:00

55 lines
2.0 KiB
Bash
Executable File

#!/usr/bin/env bash
set -o errexit -o nounset
TOP_DIR=$(cd "$(dirname "$0")/.." && pwd)
source "$TOP_DIR/config/paths"
source "$CONFIG_DIR/credentials"
source "$LIB_DIR/functions.guest.sh"
source "$CONFIG_DIR/admin-openstackrc.sh"
exec_logfile
indicate_current_auto
#------------------------------------------------------------------------------
# Set up OpenStack Networking (neutron) for compute node.
# http://docs.openstack.org/mitaka/install-guide-ubuntu/neutron-compute-install.html
#------------------------------------------------------------------------------
echo "Installing networking components for compute node."
sudo apt-get install -y neutron-linuxbridge-agent
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Configure the common component
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
echo "Configuring neutron for compute node."
conf=/etc/neutron/neutron.conf
echo "Configuring $conf."
# Configure AMQP parameters
iniset_sudo $conf DEFAULT rpc_backend rabbit
iniset_sudo $conf oslo_messaging_rabbit rabbit_host controller
iniset_sudo $conf oslo_messaging_rabbit rabbit_userid openstack
iniset_sudo $conf oslo_messaging_rabbit rabbit_password "$RABBIT_PASS"
# Configuring [DEFAULT] section
iniset_sudo $conf DEFAULT auth_strategy keystone
neutron_admin_user=$(service_to_user_name neutron)
# Configuring [keystone_authtoken] section
iniset_sudo $conf keystone_authtoken auth_uri http://controller:5000
iniset_sudo $conf keystone_authtoken auth_url http://controller:35357
iniset_sudo $conf keystone_authtoken memcached_servers controller:11211
iniset_sudo $conf keystone_authtoken auth_type password
iniset_sudo $conf keystone_authtoken project_domain_name default
iniset_sudo $conf keystone_authtoken user_domain_name default
iniset_sudo $conf keystone_authtoken project_name "$SERVICE_PROJECT_NAME"
iniset_sudo $conf keystone_authtoken username "$neutron_admin_user"
iniset_sudo $conf keystone_authtoken password "$NEUTRON_PASS"