From 7e3e9b8e9cea4f1bf78d127ffb915b79c854fdbe Mon Sep 17 00:00:00 2001 From: Ghe Rivero Date: Tue, 1 May 2012 14:34:55 +0200 Subject: Remove old flagfile support. Implements blueprint remove-old-flagfile nova-manage can still be used to convert old flagfiles style files to new .ini files: $ ./bin/nova-manage config convert --help Usage: nova-manage config convert [options] Options: -h, --help show this help message and exit --infile= old-style flagfile to convert to config --outfile= path for output file. Writes configto stdout if not specified. Change-Id: Ib8fbbd858b1db7faef70d7d97955e5042bf378f2 Signed-off-by: Ghe Rivero --- nova/utils.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'nova/utils.py') diff --git a/nova/utils.py b/nova/utils.py index 69011fb61..bf50ea4e3 100644 --- a/nova/utils.py +++ b/nova/utils.py @@ -309,12 +309,12 @@ def novadir(): return os.path.abspath(nova.__file__).split('nova/__init__.py')[0] -def default_flagfile(filename='nova.conf', args=None): +def default_cfgfile(filename='nova.conf', args=None): if args is None: args = sys.argv for arg in args: - if arg.find('flagfile') != -1: - return arg[arg.index('flagfile') + len('flagfile') + 1:] + if arg.find('config-file') != -1: + return arg[arg.index('config-file') + len('config-file') + 1:] else: if not os.path.isabs(filename): # turn relative filename into an absolute path @@ -325,8 +325,8 @@ def default_flagfile(filename='nova.conf', args=None): if not os.path.exists(filename): filename = '/etc/nova/nova.conf' if os.path.exists(filename): - flagfile = '--flagfile=%s' % filename - args.insert(1, flagfile) + cfgfile = '--config-file=%s' % filename + args.insert(1, cfgfile) return filename -- cgit