summaryrefslogtreecommitdiffstats
path: root/meta-openstack/recipes-devtools/python/python-quantum_2013.1.2.bb
diff options
context:
space:
mode:
authorMihai Prica <prica.mihai@gmail.com>2013-07-16 17:37:56 +0300
committerBruce Ashfield <bruce.ashfield@windriver.com>2013-08-28 18:41:58 -0400
commita5e335de4b26f58c3ec7c7f9b1b90953b381aea4 (patch)
treed06d9a8d8e55d91ab556c294d2f150bc19ebcedb /meta-openstack/recipes-devtools/python/python-quantum_2013.1.2.bb
parent9d06f8b343a0db944d34991af071b29028af1028 (diff)
downloadmeta-cloud-services-a5e335de4b26f58c3ec7c7f9b1b90953b381aea4.tar.gz
python-quantum: Configure postgresql credentials
The user and password for postgresql are defined in the identity class and are loaded by the recipes from this class. Signed-off-by: Mihai Prica <prica.mihai@gmail.com>
Diffstat (limited to 'meta-openstack/recipes-devtools/python/python-quantum_2013.1.2.bb')
-rw-r--r--meta-openstack/recipes-devtools/python/python-quantum_2013.1.2.bb8
1 files changed, 7 insertions, 1 deletions
diff --git a/meta-openstack/recipes-devtools/python/python-quantum_2013.1.2.bb b/meta-openstack/recipes-devtools/python/python-quantum_2013.1.2.bb
index 357cbae..8f0fa43 100644
--- a/meta-openstack/recipes-devtools/python/python-quantum_2013.1.2.bb
+++ b/meta-openstack/recipes-devtools/python/python-quantum_2013.1.2.bb
@@ -34,6 +34,12 @@ do_install_append() {
34 sed -e "s:^# core_plugin.*:core_plugin = quantum.plugins.openvswitch.ovs_quantum_plugin.OVSQuantumPluginV2:g" \ 34 sed -e "s:^# core_plugin.*:core_plugin = quantum.plugins.openvswitch.ovs_quantum_plugin.OVSQuantumPluginV2:g" \
35 -i ${WORKDIR}/quantum.conf 35 -i ${WORKDIR}/quantum.conf
36 36
37 for file in ovs_quantum_plugin.ini linuxbridge_conf.ini
38 do
39 sed -e "s:%DB_USER%:${DB_USER}:g" -i ${WORKDIR}/${file}
40 sed -e "s:%DB_PASSWORD%:${DB_PASSWORD}:g" -i ${WORKDIR}/${file}
41 done
42
37 install -d ${QUANTUM_CONF_DIR} 43 install -d ${QUANTUM_CONF_DIR}
38 install -d ${QUANTUM_CONF_DIR}/plugins/openvswitch 44 install -d ${QUANTUM_CONF_DIR}/plugins/openvswitch
39 install -d ${QUANTUM_CONF_DIR}/plugins/linuxbridge 45 install -d ${QUANTUM_CONF_DIR}/plugins/linuxbridge
@@ -65,7 +71,7 @@ pkg_postinst_${SRCNAME} () {
65 sudo -u postgres initdb -D /etc/postgresql/ 71 sudo -u postgres initdb -D /etc/postgresql/
66 /etc/init.d/postgresql start 72 /etc/init.d/postgresql start
67 sleep 0.2 73 sleep 0.2
68 sudo -u postgres psql -c "CREATE ROLE admin WITH SUPERUSER LOGIN PASSWORD 'admin'" 74 sudo -u postgres psql -c "CREATE ROLE ${DB_USER} WITH SUPERUSER LOGIN PASSWORD '${DB_PASSWORD}'"
69 fi 75 fi
70 76
71 sudo -u postgres createdb quantum 77 sudo -u postgres createdb quantum