configure mysql password for keystone and glance
diff --git a/files/glance-registry.conf b/files/glance-registry.conf
index cefb4d9..252702c 100644
--- a/files/glance-registry.conf
+++ b/files/glance-registry.conf
@@ -21,7 +21,7 @@
 # SQLAlchemy connection string for the reference implementation
 # registry server. Any valid SQLAlchemy connection string is fine.
 # See: http://www.sqlalchemy.org/docs/05/reference/sqlalchemy/connections.html#sqlalchemy.create_engine
-sql_connection = mysql://root:nova@localhost/glance
+sql_connection = mysql://root:%MYSQL_PASS%@localhost/glance
 
 # Period in seconds after which SQLAlchemy should reestablish its connection
 # to the database.
diff --git a/files/keystone.conf b/files/keystone.conf
old mode 100755
new mode 100644
index 4e775ab..5923c85
--- a/files/keystone.conf
+++ b/files/keystone.conf
@@ -49,7 +49,7 @@
 # server. Any valid SQLAlchemy connection string is fine.
 # See: http://bit.ly/ideIpI
 #sql_connection = sqlite:///keystone.db
-sql_connection = mysql://root:nova@localhost/keystone
+sql_connection = mysql://root:%MYSQL_PASS%@localhost/keystone
 backend_entities = ['UserRoleAssociation', 'Endpoints', 'Role', 'Tenant',
                     'User', 'Credentials', 'EndpointTemplates', 'Token',
                     'Service']
diff --git a/stack.sh b/stack.sh
index e0250bb..62198b2 100755
--- a/stack.sh
+++ b/stack.sh
@@ -178,7 +178,9 @@
 mysql -uroot -p$MYSQL_PASS -e 'DROP DATABASE glance;' || true
 mysql -uroot -p$MYSQL_PASS -e 'CREATE DATABASE glance;'
 # Copy over our glance-registry.conf
-cp $DIR/files/glance-registry.conf $GLANCE_DIR/etc/glance-registry.conf
+$GLANCE_CONF=$GLANCE_DIR/etc/glance-registry.conf
+cp $DIR/files/glance-registry.conf $GLANCE_CONF
+sudo sed -e "s,%MYSQL_PASS%,$MYSQL_PASS,g" -i $GLANCE_CONF
 
 # Nova
 # ----
@@ -251,6 +253,7 @@
 # FIXME (anthony) keystone should use keystone.conf.example
 KEYSTONE_CONF=$KEYSTONE_DIR/etc/keystone.conf
 cp $DIR/files/keystone.conf $KEYSTONE_CONF
+sudo sed -e "s,%MYSQL_PASS%,$MYSQL_PASS,g" -i $KEYSTONE_CONF
 
 # initialize keystone with default users/endpoints
 BIN_DIR=$KEYSTONE_DIR/bin bash $DIR/files/keystone_data.sh