From b97ca87d1f10248c08060ed0667f3c2c10dbfb1d Mon Sep 17 00:00:00 2001 From: Thomas Goirand Date: Thu, 11 Jun 2015 09:19:00 +0200 Subject: [PATCH] Added debconf screen to ask if dbsync should be done (Closes: #787536). Rewritten-From: 211e91ac0c976dd7386a8f689df1d0de8053aa41 --- trusty/debian/ceilometer-common.config.in | 2 ++ trusty/debian/ceilometer-common.postinst.in | 5 ++++- trusty/debian/ceilometer-common.templates | 11 +++++++++++ trusty/debian/changelog | 6 ++++++ 4 files changed, 23 insertions(+), 1 deletion(-) diff --git a/trusty/debian/ceilometer-common.config.in b/trusty/debian/ceilometer-common.config.in index 170b4fc..028d1d8 100644 --- a/trusty/debian/ceilometer-common.config.in +++ b/trusty/debian/ceilometer-common.config.in @@ -6,6 +6,8 @@ set -e #PKGOS-INCLUDE# +db_input high ceilometer/configure_db || true +db_go || true pkgos_rabbit_read_conf /etc/ceilometer/ceilometer.conf oslo_messaging_rabbit ceilometer pkgos_read_admin_creds /etc/ceilometer/ceilometer.conf keystone_authtoken ceilometer diff --git a/trusty/debian/ceilometer-common.postinst.in b/trusty/debian/ceilometer-common.postinst.in index 830f965..f061e5e 100644 --- a/trusty/debian/ceilometer-common.postinst.in +++ b/trusty/debian/ceilometer-common.postinst.in @@ -44,7 +44,10 @@ if [ "$1" = "configure" ] || [ "$1" = "reconfigure" ] ; then pkgos_write_new_conf ceilometer ceilometer.conf pkgos_rabbit_write_conf /etc/ceilometer/ceilometer.conf oslo_messaging_rabbit ceilometer pkgos_write_admin_creds /etc/ceilometer/ceilometer.conf keystone_authtoken ceilometer - ceilometer-dbsync || true + db_get ceilometer/configure_db + if [ "$RET" = "true" ]; then + ceilometer-dbsync || true + fi fi #DEBHELPER# diff --git a/trusty/debian/ceilometer-common.templates b/trusty/debian/ceilometer-common.templates index 66bd1b3..9c2b22e 100644 --- a/trusty/debian/ceilometer-common.templates +++ b/trusty/debian/ceilometer-common.templates @@ -7,6 +7,17 @@ # Even minor modifications require translation updates and such # changes should be coordinated with translators and reviewers. +Template: ceilometer/configure_db +Type: boolean +Default: false +_Description: Perform automatic dbsync for Ceilometer? + Ceilometer can automatically run ceilometer-dbsync after installation. For it + to work, you need an up and running mongodb-server. + . + You can change this setting later on by running "dpkg-reconfigure -plow + ceilometer". + + Template: ceilometer/rabbit_host Type: string Default: localhost diff --git a/trusty/debian/changelog b/trusty/debian/changelog index 2780580..c23fd57 100644 --- a/trusty/debian/changelog +++ b/trusty/debian/changelog @@ -1,3 +1,9 @@ +ceilometer (2015.1.0-5) unstable; urgency=medium + + * Added debconf screen to ask if dbsync should be done (Closes: #787536). + + -- Thomas Goirand Thu, 11 Jun 2015 09:18:13 +0200 + ceilometer (2015.1.0-4) unstable; urgency=medium * Added a documentation package with the sphinx docs. -- 2.32.3