summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2012-07-09 17:42:34 +0000
committerGerrit Code Review <review@openstack.org>2012-07-09 17:42:34 +0000
commit7318b1e49634e5e13fd87f66f67122a546857fa9 (patch)
tree7a910eb28a32b2cb41805ee17fd5892ff2595675 /bin
parent408a9ef25a86d777a1b0c5656d0f8baad0f00fa8 (diff)
parentabc06716d027d68f0da3b0f559fa7c85a21804d5 (diff)
downloadkeystone-7318b1e49634e5e13fd87f66f67122a546857fa9.tar.gz
keystone-7318b1e49634e5e13fd87f66f67122a546857fa9.tar.xz
keystone-7318b1e49634e5e13fd87f66f67122a546857fa9.zip
Merge "notify calling process we are ready to serve"
Diffstat (limited to 'bin')
-rwxr-xr-xbin/keystone-all11
1 files changed, 8 insertions, 3 deletions
diff --git a/bin/keystone-all b/bin/keystone-all
index 8942ec47..558161c2 100755
--- a/bin/keystone-all
+++ b/bin/keystone-all
@@ -25,6 +25,7 @@ from paste import deploy
from keystone import config
from keystone.common import wsgi
from keystone.common import utils
+from keystone.openstack.common import importutils
CONF = config.CONF
@@ -57,9 +58,13 @@ def serve(*servers):
# notify calling process we are ready to serve
if CONF.onready:
try:
- utils.check_output(CONF.onready.split())
- except Exception:
- logging.exception('Failed to execute onready command')
+ notifier = importutils.import_module(CONF.onready)
+ notifier.notify()
+ except ImportError:
+ try:
+ utils.check_output(CONF.onready.split())
+ except Exception:
+ logging.exception('Failed to execute onready command')
for server in servers:
try: