diff options
author | Chmouel Boudjnah <chmouel@chmouel.com> | 2012-03-27 22:55:39 +0100 |
---|---|---|
committer | Chmouel Boudjnah <chmouel@chmouel.com> | 2012-03-28 10:19:21 +0100 |
commit | 34e9a9771eb68ff9d98ae1b43a562eabc26849b6 (patch) | |
tree | fda930e854f8f0345ea5f49d63a129a484634a86 /bin | |
parent | 9cf91c951ed74e245693ca1f1b3df8965484dc94 (diff) | |
download | keystone-34e9a9771eb68ff9d98ae1b43a562eabc26849b6.tar.gz keystone-34e9a9771eb68ff9d98ae1b43a562eabc26849b6.tar.xz keystone-34e9a9771eb68ff9d98ae1b43a562eabc26849b6.zip |
Fix looking for config files.
- Fixes bug 966643.
Change-Id: I1e2a4d7e1765e4742bd501c4d381d94b6b7585e6
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/keystone-all | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/bin/keystone-all b/bin/keystone-all index 380ebbde..f58c2a03 100755 --- a/bin/keystone-all +++ b/bin/keystone-all @@ -8,7 +8,7 @@ import sys # If ../keystone/__init__.py exists, add ../ to Python search path, so that # it will override what happens to be installed in /usr/(local/)lib/python... -possible_topdir = os.path.normpath(os.path.join(os.path.abspath(sys.argv[0]), +possible_topdir = os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir, os.pardir)) if os.path.exists(os.path.join(possible_topdir, @@ -60,6 +60,11 @@ if __name__ == '__main__': if CONF.debug: CONF.log_opt_values(logging.getLogger(CONF.prog), logging.DEBUG) + if not CONF.config_file: + print "No config files could be found." + CONF.print_help() + sys.exit(1) + options = deploy.appconfig('config:%s' % CONF.config_file[0]) servers = [] |