From: Danny Al-Gaaf Date: Thu, 21 Mar 2013 14:08:43 +0000 (+0100) Subject: config.py: rename local function variable conf to conf_file X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=a0759f77d3224492e1664c476980c6b45bd3f7a0;p=ceph-deploy.git config.py: rename local function variable conf to conf_file Used variable name redefining 'conf' from outer scope. Signed-off-by: Danny Al-Gaaf --- diff --git a/ceph_deploy/config.py b/ceph_deploy/config.py index 749c554..f12ae8f 100644 --- a/ceph_deploy/config.py +++ b/ceph_deploy/config.py @@ -56,18 +56,18 @@ def config_pull(args): LOG.debug('Checking %s for %s', hostname, frompath) sudo = args.pushy('ssh+sudo:{hostname}'.format(hostname=hostname)) get_file_r = sudo.compile(get_file) - conf = get_file_r(path=frompath) - if conf is not None: + conf_file = get_file_r(path=frompath) + if conf_file is not None: LOG.debug('Got %s from %s', frompath, hostname) if os.path.exists(topath): with file(topath, 'rb') as f: existing = f.read() - if existing != conf and not args.overwrite_conf: + if existing != conf_file and not args.overwrite_conf: LOG.error('local config file %s exists with different content; use --overwrite-conf to overwrite' % topath) raise with file(topath, 'w') as f: - f.write(conf) + f.write(conf_file) return LOG.debug('Empty or missing %s on %s', frompath, hostname) except: