diff options
| author | Vu Tran <vu.tran@windriver.com> | 2014-09-30 12:22:12 -0400 |
|---|---|---|
| committer | Bruce Ashfield <bruce.ashfield@windriver.com> | 2014-09-30 14:30:18 -0400 |
| commit | b4d666ff63acd269b0acb2c4419643863c683750 (patch) | |
| tree | f22e20ee845a0cca1fe0f7837d92a652325ba036 /meta-openstack/recipes-devtools/python | |
| parent | 1b8a298689a95c1943f18d8d9c24589e64bbc7b7 (diff) | |
| download | meta-cloud-services-b4d666ff63acd269b0acb2c4419643863c683750.tar.gz | |
add generic monitor framework
Instead of having a central file or group of files to
describe what data resources should be monitored. The
content of these files will depend on what core system
monitoring is used ((e.g. Nagios or Monasca).
It's desirable to have each recipe describes what
it wants be monitored in generic way such that various system
monitors can understand and convert these into their format.
If a recipe wishes to register itself to system monitor, it
inherits monitor bbclass and use MONITOR_SERVICE_PACKAGES and
MONITOR_SERVICE_<package name> to indicate what processes
should should be monitored. Also MONITOR_CHECKS_<package name>
variale can be used to pass list of scripts which will be run
on target and if any of these scripts fail then will report.
Eventually monitor.bbclass will be expanded to allow recipe
to describe more complicated information passed down to
system monitor (e.g. Nagios or Monasca)
Signed-off-by: Vu Tran <vu.tran@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Diffstat (limited to 'meta-openstack/recipes-devtools/python')
19 files changed, 133 insertions, 14 deletions
diff --git a/meta-openstack/recipes-devtools/python/python-barbican_git.bb b/meta-openstack/recipes-devtools/python/python-barbican_git.bb index d5c43ff..e683743 100644 --- a/meta-openstack/recipes-devtools/python/python-barbican_git.bb +++ b/meta-openstack/recipes-devtools/python/python-barbican_git.bb | |||
| @@ -19,7 +19,7 @@ SRCREV="ada968e162d9795613bfb346a1018f63ef7025cc" | |||
| 19 | PV="2014.2.b3+git${SRCPV}" | 19 | PV="2014.2.b3+git${SRCPV}" |
| 20 | S = "${WORKDIR}/git" | 20 | S = "${WORKDIR}/git" |
| 21 | 21 | ||
| 22 | inherit update-rc.d setuptools identity hosts useradd default_configs openstackchef | 22 | inherit update-rc.d setuptools identity hosts useradd default_configs openstackchef monitor |
| 23 | 23 | ||
| 24 | SERVICECREATE_PACKAGES = "${SRCNAME}-setup" | 24 | SERVICECREATE_PACKAGES = "${SRCNAME}-setup" |
| 25 | KEYSTONE_HOST="${CONTROLLER_IP}" | 25 | KEYSTONE_HOST="${CONTROLLER_IP}" |
| @@ -136,3 +136,6 @@ RDEPENDS_${PN} += " \ | |||
| 136 | INITSCRIPT_PACKAGES = "${SRCNAME}" | 136 | INITSCRIPT_PACKAGES = "${SRCNAME}" |
| 137 | INITSCRIPT_NAME_${SRCNAME} = "barbican-api" | 137 | INITSCRIPT_NAME_${SRCNAME} = "barbican-api" |
| 138 | INITSCRIPT_PARAMS_${SRCNAME} = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 138 | INITSCRIPT_PARAMS_${SRCNAME} = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 139 | |||
| 140 | MONITOR_SERVICE_PACKAGES = "${SRCNAME}" | ||
| 141 | MONITOR_SERVICE_${SRCNAME} = "barbican" | ||
diff --git a/meta-openstack/recipes-devtools/python/python-ceilometer_git.bb b/meta-openstack/recipes-devtools/python/python-ceilometer_git.bb index d12715d..90ac1c6 100644 --- a/meta-openstack/recipes-devtools/python/python-ceilometer_git.bb +++ b/meta-openstack/recipes-devtools/python/python-ceilometer_git.bb | |||
| @@ -127,7 +127,7 @@ pkg_postinst_${SRCNAME}-setup () { | |||
| 127 | ceilometer-dbsync | 127 | ceilometer-dbsync |
| 128 | } | 128 | } |
| 129 | 129 | ||
| 130 | inherit setuptools identity hosts update-rc.d default_configs openstackchef | 130 | inherit setuptools identity hosts update-rc.d default_configs openstackchef monitor |
| 131 | 131 | ||
| 132 | PACKAGES += " ${SRCNAME}-tests" | 132 | PACKAGES += " ${SRCNAME}-tests" |
| 133 | PACKAGES += "${SRCNAME}-setup ${SRCNAME}-common ${SRCNAME}-api" | 133 | PACKAGES += "${SRCNAME}-setup ${SRCNAME}-common ${SRCNAME}-api" |
| @@ -257,3 +257,6 @@ INITSCRIPT_NAME_${SRCNAME}-alarm-evaluator = "${SRCNAME}-alarm-evaluator" | |||
| 257 | INITSCRIPT_PARAMS_${SRCNAME}-alarm-evaluator = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 257 | INITSCRIPT_PARAMS_${SRCNAME}-alarm-evaluator = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 258 | INITSCRIPT_NAME_${SRCNAME}-agent-notification = "${SRCNAME}-agent-notification" | 258 | INITSCRIPT_NAME_${SRCNAME}-agent-notification = "${SRCNAME}-agent-notification" |
| 259 | INITSCRIPT_PARAMS_${SRCNAME}-agent-notification = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 259 | INITSCRIPT_PARAMS_${SRCNAME}-agent-notification = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 260 | |||
| 261 | MONITOR_SERVICE_PACKAGES = "${SRCNAME}" | ||
| 262 | MONITOR_SERVICE_${SRCNAME} = "ceilometer" | ||
diff --git a/meta-openstack/recipes-devtools/python/python-cinder_git.bb b/meta-openstack/recipes-devtools/python/python-cinder_git.bb index ef66656..5ae149d 100644 --- a/meta-openstack/recipes-devtools/python/python-cinder_git.bb +++ b/meta-openstack/recipes-devtools/python/python-cinder_git.bb | |||
| @@ -24,7 +24,7 @@ SRCREV="58eda5d1f41082a7e1ffef66239be30b8ac1321a" | |||
| 24 | PV="2014.2.b3+git${SRCPV}" | 24 | PV="2014.2.b3+git${SRCPV}" |
| 25 | S = "${WORKDIR}/git" | 25 | S = "${WORKDIR}/git" |
| 26 | 26 | ||
| 27 | inherit setuptools update-rc.d identity default_configs hosts openstackchef | 27 | inherit setuptools update-rc.d identity default_configs hosts openstackchef monitor |
| 28 | 28 | ||
| 29 | CINDER_BACKUP_BACKEND_DRIVER ?= "cinder.backup.drivers.swift" | 29 | CINDER_BACKUP_BACKEND_DRIVER ?= "cinder.backup.drivers.swift" |
| 30 | 30 | ||
| @@ -235,3 +235,6 @@ INITSCRIPT_NAME_${SRCNAME}-scheduler = "cinder-scheduler" | |||
| 235 | INITSCRIPT_PARAMS_${SRCNAME}-scheduler = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 235 | INITSCRIPT_PARAMS_${SRCNAME}-scheduler = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 236 | INITSCRIPT_NAME_${SRCNAME}-backup = "cinder-backup" | 236 | INITSCRIPT_NAME_${SRCNAME}-backup = "cinder-backup" |
| 237 | INITSCRIPT_PARAMS_${SRCNAME}-backup = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 237 | INITSCRIPT_PARAMS_${SRCNAME}-backup = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 238 | |||
| 239 | MONITOR_SERVICE_PACKAGES = "${SRCNAME}" | ||
| 240 | MONITOR_SERVICE_${SRCNAME} = "cinder" | ||
diff --git a/meta-openstack/recipes-devtools/python/python-cinderclient/cinder-api-check.sh b/meta-openstack/recipes-devtools/python/python-cinderclient/cinder-api-check.sh new file mode 100644 index 0000000..9e64f8b --- /dev/null +++ b/meta-openstack/recipes-devtools/python/python-cinderclient/cinder-api-check.sh | |||
| @@ -0,0 +1,14 @@ | |||
| 1 | #! /bin/bash | ||
| 2 | |||
| 3 | CMD="cinder list" | ||
| 4 | |||
| 5 | data=$($CMD 2>&1) | ||
| 6 | res=$? | ||
| 7 | if [ ${res} -eq 127 ]; then | ||
| 8 | exit 0 | ||
| 9 | elif [ ${res} -ne 0 ]; then | ||
| 10 | echo "OpenStack \"cinder api\" failed: " | ||
| 11 | echo $data | ||
| 12 | exit $res | ||
| 13 | fi | ||
| 14 | exit 0 | ||
diff --git a/meta-openstack/recipes-devtools/python/python-cinderclient_git.bb b/meta-openstack/recipes-devtools/python/python-cinderclient_git.bb index c50b84f..9e0b747 100644 --- a/meta-openstack/recipes-devtools/python/python-cinderclient_git.bb +++ b/meta-openstack/recipes-devtools/python/python-cinderclient_git.bb | |||
| @@ -11,13 +11,14 @@ SRCNAME = "python-cinderclient" | |||
| 11 | SRC_URI = "\ | 11 | SRC_URI = "\ |
| 12 | git://github.com/openstack/python-cinderclient.git;branch=master \ | 12 | git://github.com/openstack/python-cinderclient.git;branch=master \ |
| 13 | file://fix_cinderclient_memory_leak.patch \ | 13 | file://fix_cinderclient_memory_leak.patch \ |
| 14 | file://cinder-api-check.sh \ | ||
| 14 | " | 15 | " |
| 15 | 16 | ||
| 16 | PV="1.1.0+git${SRCPV}" | 17 | PV="1.1.0+git${SRCPV}" |
| 17 | SRCREV="4c8464114f5539706cffc6888ce007d0d3ceba16" | 18 | SRCREV="4c8464114f5539706cffc6888ce007d0d3ceba16" |
| 18 | S = "${WORKDIR}/git" | 19 | S = "${WORKDIR}/git" |
| 19 | 20 | ||
| 20 | inherit setuptools | 21 | inherit setuptools monitor |
| 21 | 22 | ||
| 22 | DEPENDS += " \ | 23 | DEPENDS += " \ |
| 23 | python-pip \ | 24 | python-pip \ |
| @@ -41,3 +42,7 @@ do_install_append() { | |||
| 41 | 42 | ||
| 42 | PACKAGES =+ "${BPN}-bash-completion" | 43 | PACKAGES =+ "${BPN}-bash-completion" |
| 43 | FILES_${BPN}-bash-completion = "${sysconfdir}/bash_completion.d/*" | 44 | FILES_${BPN}-bash-completion = "${sysconfdir}/bash_completion.d/*" |
| 45 | |||
| 46 | MONITOR_CHECKS_${PN} += "\ | ||
| 47 | cinder-api-check.sh \ | ||
| 48 | " | ||
diff --git a/meta-openstack/recipes-devtools/python/python-glance_git.bb b/meta-openstack/recipes-devtools/python/python-glance_git.bb index fa74aca..53f2d5b 100644 --- a/meta-openstack/recipes-devtools/python/python-glance_git.bb +++ b/meta-openstack/recipes-devtools/python/python-glance_git.bb | |||
| @@ -19,7 +19,7 @@ PV="2014.2.b3+git${SRCPV}" | |||
| 19 | 19 | ||
| 20 | S = "${WORKDIR}/git" | 20 | S = "${WORKDIR}/git" |
| 21 | 21 | ||
| 22 | inherit setuptools update-rc.d identity default_configs hosts openstackchef | 22 | inherit setuptools update-rc.d identity default_configs hosts openstackchef monitor |
| 23 | 23 | ||
| 24 | GLANCE_DEFAULT_STORE ?= "file" | 24 | GLANCE_DEFAULT_STORE ?= "file" |
| 25 | GLANCE_KNOWN_STORES ?= "glance.store.rbd.Store,\ | 25 | GLANCE_KNOWN_STORES ?= "glance.store.rbd.Store,\ |
| @@ -212,3 +212,6 @@ INITSCRIPT_NAME_${SRCNAME}-api = "glance-api" | |||
| 212 | INITSCRIPT_PARAMS_${SRCNAME}-api = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 212 | INITSCRIPT_PARAMS_${SRCNAME}-api = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 213 | INITSCRIPT_NAME_${SRCNAME}-registry = "glance-registry" | 213 | INITSCRIPT_NAME_${SRCNAME}-registry = "glance-registry" |
| 214 | INITSCRIPT_PARAMS_${SRCNAME}-registry = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 214 | INITSCRIPT_PARAMS_${SRCNAME}-registry = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 215 | |||
| 216 | MONITOR_SERVICE_PACKAGES = "${SRCNAME}" | ||
| 217 | MONITOR_SERVICE_${SRCNAME} = "glance" | ||
diff --git a/meta-openstack/recipes-devtools/python/python-glanceclient/glance-api-check.sh b/meta-openstack/recipes-devtools/python/python-glanceclient/glance-api-check.sh new file mode 100644 index 0000000..aa8340a --- /dev/null +++ b/meta-openstack/recipes-devtools/python/python-glanceclient/glance-api-check.sh | |||
| @@ -0,0 +1,14 @@ | |||
| 1 | #! /bin/bash | ||
| 2 | |||
| 3 | CMD="glance image-list" | ||
| 4 | |||
| 5 | data=$($CMD 2>&1) | ||
| 6 | res=$? | ||
| 7 | if [ ${res} -eq 127 ]; then | ||
| 8 | exit 0 | ||
| 9 | elif [ ${res} -ne 0 ]; then | ||
| 10 | echo "OpenStack \"glance api\" failed: " | ||
| 11 | echo $data | ||
| 12 | exit $res | ||
| 13 | fi | ||
| 14 | exit 0 | ||
diff --git a/meta-openstack/recipes-devtools/python/python-glanceclient_git.bb b/meta-openstack/recipes-devtools/python/python-glanceclient_git.bb index 0205c49..1d8529a 100644 --- a/meta-openstack/recipes-devtools/python/python-glanceclient_git.bb +++ b/meta-openstack/recipes-devtools/python/python-glanceclient_git.bb | |||
| @@ -16,11 +16,12 @@ PR = "r0" | |||
| 16 | SRC_URI = "\ | 16 | SRC_URI = "\ |
| 17 | git://github.com/openstack/${BPN}.git;protocol=https \ | 17 | git://github.com/openstack/${BPN}.git;protocol=https \ |
| 18 | file://fix_glanceclient_memory_leak.patch \ | 18 | file://fix_glanceclient_memory_leak.patch \ |
| 19 | file://glance-api-check.sh \ | ||
| 19 | " | 20 | " |
| 20 | 21 | ||
| 21 | S = "${WORKDIR}/git" | 22 | S = "${WORKDIR}/git" |
| 22 | 23 | ||
| 23 | inherit setuptools | 24 | inherit setuptools monitor |
| 24 | 25 | ||
| 25 | FILES_${PN} += "${datadir}/${SRCNAME}" | 26 | FILES_${PN} += "${datadir}/${SRCNAME}" |
| 26 | 27 | ||
| @@ -32,3 +33,6 @@ RDEPENDS_${PN} = "gmp \ | |||
| 32 | python-pbr \ | 33 | python-pbr \ |
| 33 | " | 34 | " |
| 34 | 35 | ||
| 36 | MONITOR_CHECKS_${PN} += "\ | ||
| 37 | glance-api-check.sh \ | ||
| 38 | " | ||
diff --git a/meta-openstack/recipes-devtools/python/python-heat_git.bb b/meta-openstack/recipes-devtools/python/python-heat_git.bb index 5c73b99..8971e41 100644 --- a/meta-openstack/recipes-devtools/python/python-heat_git.bb +++ b/meta-openstack/recipes-devtools/python/python-heat_git.bb | |||
| @@ -127,7 +127,7 @@ pkg_postinst_${SRCNAME}-setup () { | |||
| 127 | heat-manage db_sync | 127 | heat-manage db_sync |
| 128 | } | 128 | } |
| 129 | 129 | ||
| 130 | inherit setuptools identity hosts update-rc.d default_configs openstackchef | 130 | inherit setuptools identity hosts update-rc.d default_configs openstackchef monitor |
| 131 | 131 | ||
| 132 | PACKAGES += "${SRCNAME}-tests ${SRCNAME}-templates ${SRCNAME}-common ${SRCNAME}-api ${SRCNAME}-api-cfn ${SRCNAME}-engine" | 132 | PACKAGES += "${SRCNAME}-tests ${SRCNAME}-templates ${SRCNAME}-common ${SRCNAME}-api ${SRCNAME}-api-cfn ${SRCNAME}-engine" |
| 133 | PACKAGES += "${SRCNAME}-setup" | 133 | PACKAGES += "${SRCNAME}-setup" |
| @@ -224,3 +224,5 @@ INITSCRIPT_PARAMS_${SRCNAME}-api-cfn = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | |||
| 224 | INITSCRIPT_NAME_${SRCNAME}-engine = "${SRCNAME}-engine" | 224 | INITSCRIPT_NAME_${SRCNAME}-engine = "${SRCNAME}-engine" |
| 225 | INITSCRIPT_PARAMS_${SRCNAME}-engine = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 225 | INITSCRIPT_PARAMS_${SRCNAME}-engine = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 226 | 226 | ||
| 227 | MONITOR_SERVICE_PACKAGES = "${SRCNAME}" | ||
| 228 | MONITOR_SERVICE_${SRCNAME} = "heat" | ||
diff --git a/meta-openstack/recipes-devtools/python/python-horizon_git.bb b/meta-openstack/recipes-devtools/python/python-horizon_git.bb index a767bee..8ee1bed 100644 --- a/meta-openstack/recipes-devtools/python/python-horizon_git.bb +++ b/meta-openstack/recipes-devtools/python/python-horizon_git.bb | |||
| @@ -60,7 +60,7 @@ SRCREV="bd998fb6094fb16d084c90de1eed619aca4c31ef" | |||
| 60 | PV="2014.2.b3+git${SRCPV}" | 60 | PV="2014.2.b3+git${SRCPV}" |
| 61 | S = "${WORKDIR}/git" | 61 | S = "${WORKDIR}/git" |
| 62 | 62 | ||
| 63 | inherit setuptools update-rc.d python-dir default_configs openstackchef | 63 | inherit setuptools update-rc.d python-dir default_configs openstackchef monitor |
| 64 | 64 | ||
| 65 | # no longer required. kept as reference. | 65 | # no longer required. kept as reference. |
| 66 | # do_install[dirs] += "${D}/usr/share/bin" | 66 | # do_install[dirs] += "${D}/usr/share/bin" |
| @@ -187,3 +187,6 @@ RDEPENDS_${SRCNAME}-apache = "\ | |||
| 187 | memcached \ | 187 | memcached \ |
| 188 | python-memcached \ | 188 | python-memcached \ |
| 189 | " | 189 | " |
| 190 | |||
| 191 | MONITOR_SERVICE_PACKAGES = "${SRCNAME}" | ||
| 192 | MONITOR_SERVICE_${SRCNAME} = "horizon" | ||
diff --git a/meta-openstack/recipes-devtools/python/python-keystone_git.bb b/meta-openstack/recipes-devtools/python/python-keystone_git.bb index 8105d6f..7512742 100644 --- a/meta-openstack/recipes-devtools/python/python-keystone_git.bb +++ b/meta-openstack/recipes-devtools/python/python-keystone_git.bb | |||
| @@ -22,7 +22,7 @@ PV="2014.2.b3+git${SRCPV}" | |||
| 22 | 22 | ||
| 23 | S = "${WORKDIR}/git" | 23 | S = "${WORKDIR}/git" |
| 24 | 24 | ||
| 25 | inherit setuptools update-rc.d identity hosts default_configs openstackchef | 25 | inherit setuptools update-rc.d identity hosts default_configs openstackchef monitor |
| 26 | 26 | ||
| 27 | SERVICE_TOKEN = "password" | 27 | SERVICE_TOKEN = "password" |
| 28 | TOKEN_FORMAT ?= "PKI" | 28 | TOKEN_FORMAT ?= "PKI" |
| @@ -301,3 +301,6 @@ RDEPENDS_${SRCNAME}-cronjobs = "cronie ${SRCNAME}" | |||
| 301 | INITSCRIPT_PACKAGES = "${SRCNAME}" | 301 | INITSCRIPT_PACKAGES = "${SRCNAME}" |
| 302 | INITSCRIPT_NAME_${SRCNAME} = "keystone" | 302 | INITSCRIPT_NAME_${SRCNAME} = "keystone" |
| 303 | INITSCRIPT_PARAMS_${SRCNAME} = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 303 | INITSCRIPT_PARAMS_${SRCNAME} = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 304 | |||
| 305 | MONITOR_SERVICE_PACKAGES = "${SRCNAME}" | ||
| 306 | MONITOR_SERVICE_${SRCNAME} = "keystone" | ||
diff --git a/meta-openstack/recipes-devtools/python/python-keystoneclient/keystone-api-check.sh b/meta-openstack/recipes-devtools/python/python-keystoneclient/keystone-api-check.sh new file mode 100644 index 0000000..aba6d5f --- /dev/null +++ b/meta-openstack/recipes-devtools/python/python-keystoneclient/keystone-api-check.sh | |||
| @@ -0,0 +1,14 @@ | |||
| 1 | #! /bin/bash | ||
| 2 | |||
| 3 | CMD="keystone endpoint-list" | ||
| 4 | |||
| 5 | data=$($CMD 2>&1) | ||
| 6 | res=$? | ||
| 7 | if [ ${res} -eq 127 ]; then | ||
| 8 | exit 0 | ||
| 9 | elif [ ${res} -ne 0 ]; then | ||
| 10 | echo "OpenStack \"keystone api\" failed: " | ||
| 11 | echo $data | ||
| 12 | exit $res | ||
| 13 | fi | ||
| 14 | exit 0 | ||
diff --git a/meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb b/meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb index e0c81db..783dca9 100644 --- a/meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb +++ b/meta-openstack/recipes-devtools/python/python-keystoneclient_git.bb | |||
| @@ -11,13 +11,14 @@ SRC_URI = "\ | |||
| 11 | git://github.com/openstack/python-keystoneclient.git;branch=master \ | 11 | git://github.com/openstack/python-keystoneclient.git;branch=master \ |
| 12 | file://fix_keystoneclient_memory_leak.patch \ | 12 | file://fix_keystoneclient_memory_leak.patch \ |
| 13 | file://keystoneclient-fix-test-path-to-example-certificates.patch \ | 13 | file://keystoneclient-fix-test-path-to-example-certificates.patch \ |
| 14 | file://keystone-api-check.sh \ | ||
| 14 | " | 15 | " |
| 15 | 16 | ||
| 16 | PV="0.10.1+git${SRCPV}" | 17 | PV="0.10.1+git${SRCPV}" |
| 17 | SRCREV="3305c7be4b726de4dcc889006d0be30eb46d3ad9" | 18 | SRCREV="3305c7be4b726de4dcc889006d0be30eb46d3ad9" |
| 18 | S = "${WORKDIR}/git" | 19 | S = "${WORKDIR}/git" |
| 19 | 20 | ||
| 20 | inherit setuptools | 21 | inherit setuptools monitor |
| 21 | 22 | ||
| 22 | FILES_${PN}-doc += "${datadir}/keystoneclient" | 23 | FILES_${PN}-doc += "${datadir}/keystoneclient" |
| 23 | 24 | ||
| @@ -54,3 +55,6 @@ RDEPENDS_${SRCNAME}-tests += " \ | |||
| 54 | python-httpretty \ | 55 | python-httpretty \ |
| 55 | " | 56 | " |
| 56 | 57 | ||
| 58 | MONITOR_CHECKS_${PN} += "\ | ||
| 59 | keystone-api-check.sh \ | ||
| 60 | " | ||
diff --git a/meta-openstack/recipes-devtools/python/python-neutron_git.bb b/meta-openstack/recipes-devtools/python/python-neutron_git.bb index f961487..6a9e66f 100644 --- a/meta-openstack/recipes-devtools/python/python-neutron_git.bb +++ b/meta-openstack/recipes-devtools/python/python-neutron_git.bb | |||
| @@ -25,7 +25,7 @@ PV="2014.2.b3+git${SRCPV}" | |||
| 25 | 25 | ||
| 26 | S = "${WORKDIR}/git" | 26 | S = "${WORKDIR}/git" |
| 27 | 27 | ||
| 28 | inherit setuptools update-rc.d identity hosts default_configs openstackchef | 28 | inherit setuptools update-rc.d identity hosts default_configs openstackchef monitor |
| 29 | 29 | ||
| 30 | SERVICECREATE_PACKAGES = "${SRCNAME}-setup" | 30 | SERVICECREATE_PACKAGES = "${SRCNAME}-setup" |
| 31 | KEYSTONE_HOST="${CONTROLLER_IP}" | 31 | KEYSTONE_HOST="${CONTROLLER_IP}" |
| @@ -313,3 +313,6 @@ INITSCRIPT_NAME_${SRCNAME}-l3-agent = "neutron-l3-agent" | |||
| 313 | INITSCRIPT_PARAMS_${SRCNAME}-l3-agent = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 313 | INITSCRIPT_PARAMS_${SRCNAME}-l3-agent = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 314 | INITSCRIPT_NAME_${SRCNAME}-metadata-agent = "neutron-metadata-agent" | 314 | INITSCRIPT_NAME_${SRCNAME}-metadata-agent = "neutron-metadata-agent" |
| 315 | INITSCRIPT_PARAMS_${SRCNAME}-metadata-agent = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 315 | INITSCRIPT_PARAMS_${SRCNAME}-metadata-agent = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 316 | |||
| 317 | MONITOR_SERVICE_PACKAGES = "${SRCNAME}" | ||
| 318 | MONITOR_SERVICE_${SRCNAME} = "neutron" | ||
diff --git a/meta-openstack/recipes-devtools/python/python-neutronclient/neutron-api-check.sh b/meta-openstack/recipes-devtools/python/python-neutronclient/neutron-api-check.sh new file mode 100644 index 0000000..160acd2 --- /dev/null +++ b/meta-openstack/recipes-devtools/python/python-neutronclient/neutron-api-check.sh | |||
| @@ -0,0 +1,14 @@ | |||
| 1 | #! /bin/bash | ||
| 2 | |||
| 3 | CMD="neutron net-list" | ||
| 4 | |||
| 5 | data=$($CMD 2>&1) | ||
| 6 | res=$? | ||
| 7 | if [ ${res} -eq 127 ]; then | ||
| 8 | exit 0 | ||
| 9 | elif [ ${res} -ne 0 ]; then | ||
| 10 | echo "OpenStack \"neutron api\" failed: " | ||
| 11 | echo $data | ||
| 12 | exit $res | ||
| 13 | fi | ||
| 14 | exit 0 | ||
diff --git a/meta-openstack/recipes-devtools/python/python-neutronclient_git.bb b/meta-openstack/recipes-devtools/python/python-neutronclient_git.bb index b4e34e3..cbad874 100644 --- a/meta-openstack/recipes-devtools/python/python-neutronclient_git.bb +++ b/meta-openstack/recipes-devtools/python/python-neutronclient_git.bb | |||
| @@ -22,13 +22,14 @@ PR = "r0" | |||
| 22 | 22 | ||
| 23 | SRC_URI = "git://github.com/openstack/python-neutronclient.git;branch=master \ | 23 | SRC_URI = "git://github.com/openstack/python-neutronclient.git;branch=master \ |
| 24 | file://neutronclient-use-csv-flag-instead-of-json.patch \ | 24 | file://neutronclient-use-csv-flag-instead-of-json.patch \ |
| 25 | file://neutron-api-check.sh \ | ||
| 25 | " | 26 | " |
| 26 | 27 | ||
| 27 | PV="2.3.7+git${SRCPV}" | 28 | PV="2.3.7+git${SRCPV}" |
| 28 | SRCREV="1452193f935f5be0bb2f5f01b54bd4947d27331b" | 29 | SRCREV="1452193f935f5be0bb2f5f01b54bd4947d27331b" |
| 29 | S = "${WORKDIR}/git" | 30 | S = "${WORKDIR}/git" |
| 30 | 31 | ||
| 31 | inherit setuptools | 32 | inherit setuptools monitor |
| 32 | 33 | ||
| 33 | PACKAGECONFIG ?= "bash-completion" | 34 | PACKAGECONFIG ?= "bash-completion" |
| 34 | PACKAGECONFIG[bash-completion] = ",,bash-completion,bash-completion ${BPN}-bash-completion" | 35 | PACKAGECONFIG[bash-completion] = ",,bash-completion,bash-completion ${BPN}-bash-completion" |
| @@ -40,3 +41,7 @@ do_install_append() { | |||
| 40 | 41 | ||
| 41 | PACKAGES =+ "${BPN}-bash-completion" | 42 | PACKAGES =+ "${BPN}-bash-completion" |
| 42 | FILES_${BPN}-bash-completion = "${sysconfdir}/bash_completion.d/*" | 43 | FILES_${BPN}-bash-completion = "${sysconfdir}/bash_completion.d/*" |
| 44 | |||
| 45 | MONITOR_CHECKS_${PN} += "\ | ||
| 46 | neutron-api-check.sh \ | ||
| 47 | " | ||
diff --git a/meta-openstack/recipes-devtools/python/python-nova_git.bb b/meta-openstack/recipes-devtools/python/python-nova_git.bb index 5a8ba84..e79302b 100644 --- a/meta-openstack/recipes-devtools/python/python-nova_git.bb +++ b/meta-openstack/recipes-devtools/python/python-nova_git.bb | |||
| @@ -30,7 +30,7 @@ PV="2014.2.b3+git${SRCPV}" | |||
| 30 | 30 | ||
| 31 | S = "${WORKDIR}/git" | 31 | S = "${WORKDIR}/git" |
| 32 | 32 | ||
| 33 | inherit update-rc.d setuptools identity hosts useradd default_configs openstackchef | 33 | inherit update-rc.d setuptools identity hosts useradd default_configs openstackchef monitor |
| 34 | 34 | ||
| 35 | LIBVIRT_IMAGES_TYPE ?= "default" | 35 | LIBVIRT_IMAGES_TYPE ?= "default" |
| 36 | 36 | ||
| @@ -368,3 +368,6 @@ INITSCRIPT_PARAMS_${SRCNAME}-novncproxy = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | |||
| 368 | 368 | ||
| 369 | INITSCRIPT_NAME_${SRCNAME}-spicehtml5proxy = "nova-spicehtml5proxy" | 369 | INITSCRIPT_NAME_${SRCNAME}-spicehtml5proxy = "nova-spicehtml5proxy" |
| 370 | INITSCRIPT_PARAMS_${SRCNAME}-spicehtml5proxy = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 370 | INITSCRIPT_PARAMS_${SRCNAME}-spicehtml5proxy = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 371 | |||
| 372 | MONITOR_SERVICE_PACKAGES = "${SRCNAME}" | ||
| 373 | MONITOR_SERVICE_${SRCNAME} = "nova-api nova-cert nova-conductor nova-consoleauth nova-scheduler" | ||
diff --git a/meta-openstack/recipes-devtools/python/python-novaclient/nova-api-check.sh b/meta-openstack/recipes-devtools/python/python-novaclient/nova-api-check.sh new file mode 100644 index 0000000..b9ba6bc --- /dev/null +++ b/meta-openstack/recipes-devtools/python/python-novaclient/nova-api-check.sh | |||
| @@ -0,0 +1,14 @@ | |||
| 1 | #! /bin/bash | ||
| 2 | |||
| 3 | CMD="nova list" | ||
| 4 | |||
| 5 | data=$($CMD 2>&1) | ||
| 6 | res=$? | ||
| 7 | if [ ${res} -eq 127 ]; then | ||
| 8 | exit 0 | ||
| 9 | elif [ ${res} -ne 0 ]; then | ||
| 10 | echo "OpenStack \"nova api\" failed: " | ||
| 11 | echo $data | ||
| 12 | exit $res | ||
| 13 | fi | ||
| 14 | exit 0 | ||
diff --git a/meta-openstack/recipes-devtools/python/python-novaclient_git.bb b/meta-openstack/recipes-devtools/python/python-novaclient_git.bb index e8f5aa3..a7a501c 100644 --- a/meta-openstack/recipes-devtools/python/python-novaclient_git.bb +++ b/meta-openstack/recipes-devtools/python/python-novaclient_git.bb | |||
| @@ -10,13 +10,14 @@ SRC_URI = "\ | |||
| 10 | git://github.com/openstack/python-novaclient.git;branch=master \ | 10 | git://github.com/openstack/python-novaclient.git;branch=master \ |
| 11 | file://fix_novaclient_memory_leak.patch \ | 11 | file://fix_novaclient_memory_leak.patch \ |
| 12 | file://novaclient-specify-full-path-to-test-certificate.patch \ | 12 | file://novaclient-specify-full-path-to-test-certificate.patch \ |
| 13 | file://nova-api-check.sh \ | ||
| 13 | " | 14 | " |
| 14 | 15 | ||
| 15 | PV="2.18.1+git${SRCPV}" | 16 | PV="2.18.1+git${SRCPV}" |
| 16 | SRCREV="2a1c07e790cc95b1e847974e4c757f826507834f" | 17 | SRCREV="2a1c07e790cc95b1e847974e4c757f826507834f" |
| 17 | S = "${WORKDIR}/git" | 18 | S = "${WORKDIR}/git" |
| 18 | 19 | ||
| 19 | inherit setuptools | 20 | inherit setuptools monitor |
| 20 | 21 | ||
| 21 | DEPENDS = "python-setuptools-git" | 22 | DEPENDS = "python-setuptools-git" |
| 22 | DEPENDS += " \ | 23 | DEPENDS += " \ |
| @@ -44,3 +45,7 @@ do_install_append() { | |||
| 44 | 45 | ||
| 45 | PACKAGES =+ "${BPN}-bash-completion" | 46 | PACKAGES =+ "${BPN}-bash-completion" |
| 46 | FILES_${BPN}-bash-completion = "${sysconfdir}/bash_completion.d/*" | 47 | FILES_${BPN}-bash-completion = "${sysconfdir}/bash_completion.d/*" |
| 48 | |||
| 49 | MONITOR_CHECKS_${PN} += "\ | ||
| 50 | nova-api-check.sh \ | ||
| 51 | " | ||
