diff --git a/flavours/nova-vm/first-boot.d/15-mysql b/flavours/nova-vm/first-boot.d/15-mysql index fc89f0e2..fe3d5a30 100755 --- a/flavours/nova-vm/first-boot.d/15-mysql +++ b/flavours/nova-vm/first-boot.d/15-mysql @@ -26,15 +26,16 @@ sqltfile=`mktemp` cat < $sqltfile CREATE DATABASE IF NOT EXISTS nova; GRANT ALL PRIVILEGES ON nova.* TO 'nova'@'%' IDENTIFIED BY '${MYSQL_NOVAPASS}'; +GRANT ALL PRIVILEGES ON nova.* TO 'nova'@'localhost' IDENTIFIED BY '${MYSQL_NOVAPASS}'; CREATE DATABASE IF NOT EXISTS cinder; -GRANT ALL PRIVILEGES ON cinder.* TO 'cinder'@'%' IDENTIFIED BY '${MYSQL_CINDERPASS}'; +GRANT ALL PRIVILEGES ON cinder.* TO 'cinder'@'localhost' IDENTIFIED BY '${MYSQL_CINDERPASS}'; CREATE DATABASE IF NOT EXISTS keystone; -GRANT ALL PRIVILEGES ON keystone.* TO 'keystone'@'%' IDENTIFIED BY '${MYSQL_KEYSTONEPASS}'; +GRANT ALL PRIVILEGES ON keystone.* TO 'keystone'@'localhost' IDENTIFIED BY '${MYSQL_KEYSTONEPASS}'; CREATE DATABASE IF NOT EXISTS glance; -GRANT ALL PRIVILEGES ON glance.* TO 'glance'@'%' IDENTIFIED BY '${MYSQL_GLANCEPASS}'; +GRANT ALL PRIVILEGES ON glance.* TO 'glance'@'localhost' IDENTIFIED BY '${MYSQL_GLANCEPASS}'; FLUSH PRIVILEGES; EOF diff --git a/flavours/nova-vm/first-boot.d/20-rabbitmq b/flavours/nova-vm/first-boot.d/20-rabbitmq index 892f1654..62d5d442 100755 --- a/flavours/nova-vm/first-boot.d/20-rabbitmq +++ b/flavours/nova-vm/first-boot.d/20-rabbitmq @@ -5,4 +5,4 @@ set -o xtrace source $(dirname $0)/defaults #RABBIT_PASS -rabbitmqctl change_password guest $̣{RABBIT_PASS} +rabbitmqctl change_password guest ${RABBIT_PASS} diff --git a/flavours/nova-vm/first-boot.d/31-keystone-data b/flavours/nova-vm/first-boot.d/31-keystone-data index e67187a6..07ae48a6 100755 --- a/flavours/nova-vm/first-boot.d/31-keystone-data +++ b/flavours/nova-vm/first-boot.d/31-keystone-data @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash # # Keystone Datas # @@ -11,15 +11,15 @@ # Support: openstack@lists.launchpad.net # License: Apache Software License (ASL) 2.0 # - source $(dirname $0)/defaults export OS_TENANT_NAME=admin -export OS_USER_NAME=admin +export OS_USERNAME=admin export OS_PASSWORD=${ADMIN_PASSWORD} export OS_AUTH_URL="http://localhost:5000/v2.0/" export SERVICE_ENDPOINT="http://localhost:35357/v2.0" SERVICE_TENANT_NAME=${SERVICE_TENANT_NAME:-service} +export SERVICE_TOKEN=${SERVICE_TOKEN} get_id () { echo `$@ | awk '/ id / { print $4 }'` diff --git a/flavours/nova-vm/first-boot.d/32-keystone-endpoints b/flavours/nova-vm/first-boot.d/32-keystone-endpoints index 4d8bc29a..18f80b77 100755 --- a/flavours/nova-vm/first-boot.d/32-keystone-endpoints +++ b/flavours/nova-vm/first-boot.d/32-keystone-endpoints @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash # # Keystone Endpoints # @@ -11,7 +11,6 @@ # Support: openstack@lists.launchpad.net # License: Apache Software License (ASL) 2.0 # - source $(dirname $0)/defaults # MySQL definitions @@ -21,8 +20,8 @@ MYSQL_HOST=localhost # Keystone definitions KEYSTONE_REGION=RegionOne -SERVICE_TOKEN=password -SERVICE_ENDPOINT="http://localhost:35357/v2.0" +export SERVICE_TOKEN=password +export SERVICE_ENDPOINT="http://localhost:35357/v2.0" keystone service-create --name nova --type compute --description 'OpenStack Compute Service' keystone service-create --name cinder --type volume --description 'OpenStack Volume Service' diff --git a/flavours/nova-vm/first-boot.d/50-nova b/flavours/nova-vm/first-boot.d/50-nova index 76ecf58b..ebf08062 100755 --- a/flavours/nova-vm/first-boot.d/50-nova +++ b/flavours/nova-vm/first-boot.d/50-nova @@ -7,8 +7,7 @@ source $(dirname $0)/defaults NOVA_DIR="/etc/nova/" -SQL_CONNECTION="mysql://nova:${MYSQL_NOVAPASS}d@localhost:3306/nova" - +SQL_CONNECTION="mysql://nova:${MYSQL_NOVAPASS}@localhost:3306/nova" sed -e "s,^admin_tenant_name\s*=\s*.\+$,admin_tenant_name = service," -i ${NOVA_DIR}/api-paste.ini sed -e "s,^admin_user\s*=\s*.\+$,admin_user = nova," -i ${NOVA_DIR}/api-paste.ini