Add check on config file in sync_db script

Change-Id: Id8ce0ea35dd6bf05caca2e5133c855157e11c828
This commit is contained in:
Nikolay Mahotkin 2014-09-11 13:25:46 +04:00
parent 636e5290bc
commit 9c6fe87129

View File

@ -26,6 +26,11 @@ LOG = logging.getLogger(__name__)
def main(): def main():
config.parse_args() config.parse_args()
if len(CONF.config_file) == 0:
print "Usage: sync_db --config-file <path-to-config-file>"
return exit(1)
logging.setup('Mistral') logging.setup('Mistral')
db_api.setup_db() db_api.setup_db()