diff options
Diffstat (limited to 'meta-openstack/recipes-devtools/python/python-nova_2013.1.bb')
| -rw-r--r-- | meta-openstack/recipes-devtools/python/python-nova_2013.1.bb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/meta-openstack/recipes-devtools/python/python-nova_2013.1.bb b/meta-openstack/recipes-devtools/python/python-nova_2013.1.bb index dbe4d4f..0c59c2d 100644 --- a/meta-openstack/recipes-devtools/python/python-nova_2013.1.bb +++ b/meta-openstack/recipes-devtools/python/python-nova_2013.1.bb | |||
| @@ -76,6 +76,14 @@ pkg_postinst_${SRCNAME}-controller () { | |||
| 76 | exit 1 | 76 | exit 1 |
| 77 | fi | 77 | fi |
| 78 | 78 | ||
| 79 | # This is to make sure postgres is configured and running | ||
| 80 | if ! pidof postmaster > /dev/null; then | ||
| 81 | sudo -u postgres initdb -D /etc/postgresql/ | ||
| 82 | /etc/init.d/postgresql start | ||
| 83 | sleep 0.2 | ||
| 84 | sudo -u postgres psql -c "CREATE ROLE admin WITH SUPERUSER LOGIN PASSWORD 'admin'" | ||
| 85 | fi | ||
| 86 | |||
| 79 | sudo -u postgres createdb nova | 87 | sudo -u postgres createdb nova |
| 80 | nova-manage db sync | 88 | nova-manage db sync |
| 81 | } | 89 | } |
