aboutsummaryrefslogtreecommitdiffstats
path: root/meta-openstack/recipes-devtools/python/python-rally_git.bb
diff options
context:
space:
mode:
Diffstat (limited to 'meta-openstack/recipes-devtools/python/python-rally_git.bb')
-rw-r--r--meta-openstack/recipes-devtools/python/python-rally_git.bb28
1 files changed, 13 insertions, 15 deletions
diff --git a/meta-openstack/recipes-devtools/python/python-rally_git.bb b/meta-openstack/recipes-devtools/python/python-rally_git.bb
index d29e7cb1..31d42424 100644
--- a/meta-openstack/recipes-devtools/python/python-rally_git.bb
+++ b/meta-openstack/recipes-devtools/python/python-rally_git.bb
@@ -63,22 +63,20 @@ do_install_append() {
}
pkg_postinst_${SRCNAME}-setup () {
- if [ "x$D" != "x" ]; then
- exit 1
+ if [ -z "$D" ]; then
+ # This is to make sure postgres is configured and running
+ if ! pidof postmaster > /dev/null; then
+ /etc/init.d/postgresql-init
+ /etc/init.d/postgresql start
+ fi
+
+ if [ ! -d /var/log/rally ]; then
+ mkdir /var/log/rally
+ fi
+
+ sudo -u postgres createdb rally
+ rally-manage db recreate
fi
-
- # This is to make sure postgres is configured and running
- if ! pidof postmaster > /dev/null; then
- /etc/init.d/postgresql-init
- /etc/init.d/postgresql start
- fi
-
- if [ ! -d /var/log/rally ]; then
- mkdir /var/log/rally
- fi
-
- sudo -u postgres createdb rally
- rally-manage db recreate
}
PACKAGES += "${SRCNAME}-tests ${SRCNAME}-api ${SRCNAME} ${SRCNAME}-setup"