fix: rqfile default.yaml, flake8

This commit is contained in:
adobdin 2016-08-03 15:02:17 +00:00
parent 666a21cb17
commit eeeb83c558
2 changed files with 3 additions and 4 deletions

View File

@ -40,14 +40,13 @@ def load_conf(filename):
conf['timeout'] = 15
conf['prefix'] = 'nice -n 19 ionice -c 3'
rqdir = 'rq'
rqfile = 'rq/default.yaml'
rqfile = 'default.yaml'
dtm = os.path.join(os.path.abspath(os.sep), 'usr', 'share', 'timmy')
if os.path.isdir(os.path.join(dtm, rqdir)):
conf['rqdir'] = os.path.join(dtm, rqdir)
conf['rqfile'] = os.path.join(conf['rqdir'], rqfile)
else:
conf['rqdir'] = rqdir
conf['rqfile'] = rqfile
conf['rqfile'] = os.path.join(conf['rqdir'], rqfile)
conf['compress_timeout'] = 3600
conf['outdir'] = os.path.join(gettempdir(), 'timmy', 'info')
conf['archive_dir'] = os.path.join(gettempdir(), 'timmy', 'archives')

View File

@ -943,7 +943,7 @@ class NodeManager(object):
cmd = ("tar --gzip -C %s --create --warning=no-file-changed "
" --file - --null --files-from -" % os.path.abspath(os.sep))
if self.conf['logs_speed_limit']:
if not (node.ip == 'localhost' or node.ip.startswith('127.')):
if not (node.ip == 'localhost' or node.ip.startswith('127.')):
cmd = ' '.join([cmd, limitcmd])
args = {'cmd': cmd,
'timeout': timeout,