when doing ceilometer in a multihost devstack, you don't want
ceilometer-api running on the computes. Under -o errexit this
became fatal.
Change-Id: Ie43c8724ba467b810f5a3b075dea45d66dde8648
| ... | ... |
@@ -206,9 +206,12 @@ function start_ceilometer {
|
| 206 | 206 |
screen_it ceilometer-collector "cd ; ceilometer-collector --config-file $CEILOMETER_CONF" |
| 207 | 207 |
screen_it ceilometer-api "cd ; ceilometer-api -d -v --log-dir=$CEILOMETER_API_LOG_DIR --config-file $CEILOMETER_CONF" |
| 208 | 208 |
|
| 209 |
- echo "Waiting for ceilometer-api to start..." |
|
| 210 |
- if ! timeout $SERVICE_TIMEOUT sh -c "while ! curl --noproxy '*' -s http://localhost:8777/v2/ >/dev/null; do sleep 1; done"; then |
|
| 211 |
- die $LINENO "ceilometer-api did not start" |
|
| 209 |
+ # only die on API if it was actually intended to be turned on |
|
| 210 |
+ if service_enabled ceilometer-api; then |
|
| 211 |
+ echo "Waiting for ceilometer-api to start..." |
|
| 212 |
+ if ! timeout $SERVICE_TIMEOUT sh -c "while ! curl --noproxy '*' -s http://localhost:8777/v2/ >/dev/null; do sleep 1; done"; then |
|
| 213 |
+ die $LINENO "ceilometer-api did not start" |
|
| 214 |
+ fi |
|
| 212 | 215 |
fi |
| 213 | 216 |
|
| 214 | 217 |
screen_it ceilometer-alarm-notifier "cd ; ceilometer-alarm-notifier --config-file $CEILOMETER_CONF" |