Merge "add /check.sh script to nova-api image"

This commit is contained in:
Jenkins 2014-10-16 20:53:50 +00:00 committed by Gerrit Code Review
commit a3b90f59f1
2 changed files with 19 additions and 0 deletions

View File

@ -7,4 +7,6 @@ RUN yum -y install \
EXPOSE 8773 8774 8775
ADD ./start.sh /start.sh
ADD ./check.sh /check.sh
CMD ["/start.sh"]

View File

@ -0,0 +1,17 @@
#!/bin/sh
RES=0
. /openrc
if ! keystone token-get > /dev/null; then
echo "ERROR: keystone token-get failed" >&2
RES=1
else
if ! nova list > /dev/null; then
echo "ERROR: nova list failed" >&2
RES=1
fi
fi
exit $RES