CI tests: fix SSSD log collecting

Wildcard '*' has not been working for log collecting. I just set
the whole SSSD log directory to be collected. tar utility is able to
archive whole directories.

Reviewed-By: David Kupka <dkupka@redhat.com>
Reviewed-By: Martin Babinsky <mbabinsk@redhat.com>
This commit is contained in:
Martin Basti 2016-07-20 17:35:32 +02:00 committed by Martin Babinsky
parent f05615bb83
commit ae623864ee
2 changed files with 4 additions and 3 deletions

View File

@ -91,8 +91,9 @@ def collect_logs(name, logs_dict, logfile_dir=None, beakerlib_plugin=None):
log.info('Collecting logs from: %s', host.hostname)
# Tar up the logs on the remote server
cmd = host.run_command(['tar', 'cJv'] + logs, log_stdout=False,
raiseonerr=False)
cmd = host.run_command(
['tar', '-c', '--ignore-failed-read', '-J', '-v'] + logs,
log_stdout=False, raiseonerr=False)
if cmd.returncode:
log.warning('Could not collect all requested logs')

View File

@ -559,7 +559,7 @@ def setup_sssd_debugging(host):
paths.SSSD_CONF],
raiseonerr=False)
host.collect_log(os.path.join(paths.VAR_LOG_SSSD_DIR, '*'))
host.collect_log(os.path.join(paths.VAR_LOG_SSSD_DIR))
# Clear the cache and restart SSSD
clear_sssd_cache(host)