summaryrefslogtreecommitdiffstats
path: root/meta-openstack/recipes-devtools/python/python-ceilometer_git.bb
diff options
context:
space:
mode:
authorAndy Ning <andy.ning@windriver.com>2014-07-16 11:37:37 -0400
committerBruce Ashfield <bruce.ashfield@windriver.com>2014-07-31 15:15:31 -0400
commitbe2e56c0bbd019e450beca62f1cad13cf5fe37e4 (patch)
tree7cbf2f17513a79242709706558af68682100bc00 /meta-openstack/recipes-devtools/python/python-ceilometer_git.bb
parentf300718c549178e924699d4b8de7f98a7bad6375 (diff)
downloadmeta-cloud-services-be2e56c0bbd019e450beca62f1cad13cf5fe37e4.tar.gz
Keystone: package service/user additions
Instead of creating tenant/user/role and service/endpoint for all openstack services in keystone postinstall, now each of the services creates its own keystone identities by queueing them up in its postinstall to a file /etc/keystone/service-user-setup. service-user-setup script, when run as the last postinstall, calls identity.sh with keystone identity parameters to create necessary identities for the services. Signed-off-by: Andy Ning <andy.ning@windriver.com>
Diffstat (limited to 'meta-openstack/recipes-devtools/python/python-ceilometer_git.bb')
-rw-r--r--meta-openstack/recipes-devtools/python/python-ceilometer_git.bb31
1 files changed, 30 insertions, 1 deletions
diff --git a/meta-openstack/recipes-devtools/python/python-ceilometer_git.bb b/meta-openstack/recipes-devtools/python/python-ceilometer_git.bb
index c3354c0..6e58cac 100644
--- a/meta-openstack/recipes-devtools/python/python-ceilometer_git.bb
+++ b/meta-openstack/recipes-devtools/python/python-ceilometer_git.bb
@@ -23,6 +23,32 @@ S = "${WORKDIR}/git"
23 23
24CEILOMETER_SECRET ?= "12121212" 24CEILOMETER_SECRET ?= "12121212"
25 25
26SERVICECREATE_PACKAGES = "${SRCNAME}-setup ${SRCNAME}-reseller"
27KEYSTONE_HOST="${CONTROLLER_IP}"
28
29# USERCREATE_PARAM and SERVICECREATE_PARAM contain the list of parameters to be set.
30# If the flag for a parameter in the list is not set here, the default value will be given to that parameter.
31# Parameters not in the list will be set to empty.
32
33USERCREATE_PARAM_${SRCNAME}-setup = "name pass tenant role email"
34SERVICECREATE_PARAM_${SRCNAME}-setup = "name type description region publicurl adminurl internalurl"
35python () {
36 flags = {'type':'metering',\
37 'description':'OpenStack Metering Service',\
38 'publicurl':"'http://${KEYSTONE_HOST}:8777/'",\
39 'adminurl':"'http://${KEYSTONE_HOST}:8777/'",\
40 'internalurl':"'http://${KEYSTONE_HOST}:8777/'"}
41
42 d.setVarFlags("SERVICECREATE_PARAM_%s-setup" % d.getVar('SRCNAME',True), flags)
43}
44
45# Add service user to service tenant as ResellerAdmin role
46USERCREATE_PARAM_${SRCNAME}-reseller = "name pass tenant role email"
47python () {
48 flags = {'role':'ResellerAdmin'}
49 d.setVarFlags("USERCREATE_PARAM_%s-reseller" % d.getVar('SRCNAME',True), flags)
50}
51
26do_configure_append() { 52do_configure_append() {
27 # We are using postgresql support, hence this requirement is not valid 53 # We are using postgresql support, hence this requirement is not valid
28 # removing it, to avoid on-target runtime issues 54 # removing it, to avoid on-target runtime issues
@@ -104,8 +130,10 @@ PACKAGES += "${SRCNAME}-setup ${SRCNAME}-common ${SRCNAME}-api"
104PACKAGES += "${SRCNAME}-alarm-notifier ${SRCNAME}-alarm-evaluator" 130PACKAGES += "${SRCNAME}-alarm-notifier ${SRCNAME}-alarm-evaluator"
105PACKAGES += "${SRCNAME}-agent-notification" 131PACKAGES += "${SRCNAME}-agent-notification"
106PACKAGES += "${SRCNAME}-collector ${SRCNAME}-compute ${SRCNAME}-controller" 132PACKAGES += "${SRCNAME}-collector ${SRCNAME}-compute ${SRCNAME}-controller"
133PACKAGES += " ${SRCNAME}-reseller"
107 134
108ALLOW_EMPTY_${SRCNAME}-setup = "1" 135ALLOW_EMPTY_${SRCNAME}-setup = "1"
136ALLOW_EMPTY_${SRCNAME}-reseller = "1"
109 137
110FILES_${PN} = "${libdir}/*" 138FILES_${PN} = "${libdir}/*"
111 139
@@ -199,12 +227,13 @@ RDEPENDS_${PN} += " \
199 python-pysnmp \ 227 python-pysnmp \
200 " 228 "
201 229
202RDEPENDS_${SRCNAME}-controller = "${PN} ${SRCNAME}-common ${SRCNAME}-alarm-notifier ${SRCNAME}-alarm-evaluator ${SRCNAME}-agent-notification \ 230RDEPENDS_${SRCNAME}-controller = "${PN} ${SRCNAME}-common ${SRCNAME}-alarm-notifier ${SRCNAME}-alarm-evaluator ${SRCNAME}-agent-notification ${SRCNAME}-reseller \
203 postgresql postgresql-client python-psycopg2 tgt" 231 postgresql postgresql-client python-psycopg2 tgt"
204RDEPENDS_${SRCNAME}-api = "${SRCNAME}-controller" 232RDEPENDS_${SRCNAME}-api = "${SRCNAME}-controller"
205RDEPENDS_${SRCNAME}-collector = "${SRCNAME}-controller" 233RDEPENDS_${SRCNAME}-collector = "${SRCNAME}-controller"
206RDEPENDS_${SRCNAME}-compute = "${PN} ${SRCNAME}-common python-ceilometerclient libvirt" 234RDEPENDS_${SRCNAME}-compute = "${PN} ${SRCNAME}-common python-ceilometerclient libvirt"
207RDEPENDS_${SRCNAME}-setup = "postgresql sudo ${SRCNAME}-controller" 235RDEPENDS_${SRCNAME}-setup = "postgresql sudo ${SRCNAME}-controller"
236RDEPENDS_${SRCNAME}-reseller = "postgresql sudo ${SRCNAME}-controller"
208 237
209INITSCRIPT_PACKAGES = "${SRCNAME}-api ${SRCNAME}-collector ${SRCNAME}-compute ${SRCNAME}-controller" 238INITSCRIPT_PACKAGES = "${SRCNAME}-api ${SRCNAME}-collector ${SRCNAME}-compute ${SRCNAME}-controller"
210INITSCRIPT_PACKAGES += "${SRCNAME}-alarm-notifier ${SRCNAME}-alarm-evaluator ${SRCNAME}-agent-notification" 239INITSCRIPT_PACKAGES += "${SRCNAME}-alarm-notifier ${SRCNAME}-alarm-evaluator ${SRCNAME}-agent-notification"