Rename subunit_log.txt to testrepository.subunit
Subunit is not a text protocol - it tunnels itself in stdout, but that is not the same thing. The .txt extension leads to bad headers from Apache: wget -S http://logs.openstack.org/.../logs/subunit_log.txt.gz HTTP/1.1 200 OK Date: Sun, 31 Aug 2014 23:40:07 GMT Server: Apache/2.2.22 (Ubuntu) Vary: Accept-Encoding Keep-Alive: timeout=5, max=100 Connection: Keep-Alive Transfer-Encoding: chunked Content-Type: text/plain which are clearly bogus - and worse cause wget and curl to treat this as a plain text file - so they apply line ending transformations to it which breaks the contents. Some browsers are smarter when one does 'save link' - but all in all its a poor thing to present a binary object as text. Don't be confused by the lack of Content-Encoding on the object - thats a separate issue. Change-Id: Iacb501e8615a184424f865561cac18c5aa1da1f0
This commit is contained in:
36
functions.sh
36
functions.sh
@@ -616,32 +616,32 @@ function cleanup_host {
|
||||
|
||||
# Process testr artifacts.
|
||||
if [ -f $BASE/new/tempest/.testrepository/0 ]; then
|
||||
sudo cp $BASE/new/tempest/.testrepository/0 $BASE/logs/subunit_log.txt
|
||||
sudo python /usr/local/jenkins/slave_scripts/subunit2html.py $BASE/logs/subunit_log.txt $BASE/logs/testr_results.html
|
||||
sudo gzip -9 $BASE/logs/subunit_log.txt
|
||||
sudo cp $BASE/new/tempest/.testrepository/0 $BASE/logs/testrepository.subunit
|
||||
sudo python /usr/local/jenkins/slave_scripts/subunit2html.py $BASE/logs/testrepository.subunit $BASE/logs/testr_results.html
|
||||
sudo gzip -9 $BASE/logs/testrepository.subunit
|
||||
sudo gzip -9 $BASE/logs/testr_results.html
|
||||
sudo chown jenkins:jenkins $BASE/logs/subunit_log.txt.gz $BASE/logs/testr_results.html.gz
|
||||
sudo chmod a+r $BASE/logs/subunit_log.txt.gz $BASE/logs/testr_results.html.gz
|
||||
sudo chown jenkins:jenkins $BASE/logs/testrepository.subunit.gz $BASE/logs/testr_results.html.gz
|
||||
sudo chmod a+r $BASE/logs/testrepository.subunit.gz $BASE/logs/testr_results.html.gz
|
||||
elif [ -f $BASE/new/tempest/.testrepository/tmp* ]; then
|
||||
# If testr timed out, collect temp file from testr
|
||||
sudo cp $BASE/new/tempest/.testrepository/tmp* $BASE/logs/subunit_log.txt
|
||||
sudo gzip -9 $BASE/logs/subunit_log.txt
|
||||
sudo chown jenkins:jenkins $BASE/logs/subunit_log.txt.gz
|
||||
sudo chmod a+r $BASE/logs/subunit_log.txt.gz
|
||||
sudo cp $BASE/new/tempest/.testrepository/tmp* $BASE/logs/testrepository.subunit
|
||||
sudo gzip -9 $BASE/logs/testrepository.subunit
|
||||
sudo chown jenkins:jenkins $BASE/logs/testrepository.subunit.gz
|
||||
sudo chmod a+r $BASE/logs/testrepository.subunit.gz
|
||||
fi
|
||||
if [ -f $BASE/old/tempest/.testrepository/0 ]; then
|
||||
sudo cp $BASE/old/tempest/.testrepository/0 $BASE/logs/old/subunit_log.txt
|
||||
sudo python /usr/local/jenkins/slave_scripts/subunit2html.py $BASE/logs/old/subunit_log.txt $BASE/logs/old/testr_results.html
|
||||
sudo gzip -9 $BASE/logs/old/subunit_log.txt
|
||||
sudo cp $BASE/old/tempest/.testrepository/0 $BASE/logs/old/testrepository.subunit
|
||||
sudo python /usr/local/jenkins/slave_scripts/subunit2html.py $BASE/logs/old/testrepository.subunit $BASE/logs/old/testr_results.html
|
||||
sudo gzip -9 $BASE/logs/old/testrepository.subunit
|
||||
sudo gzip -9 $BASE/logs/old/testr_results.html
|
||||
sudo chown jenkins:jenkins $BASE/logs/old/subunit_log.txt.gz $BASE/logs/old/testr_results.html.gz
|
||||
sudo chmod a+r $BASE/logs/old/subunit_log.txt.gz $BASE/logs/old/testr_results.html.gz
|
||||
sudo chown jenkins:jenkins $BASE/logs/old/testrepository.subunit.gz $BASE/logs/old/testr_results.html.gz
|
||||
sudo chmod a+r $BASE/logs/old/testrepository.subunit.gz $BASE/logs/old/testr_results.html.gz
|
||||
elif [ -f $BASE/old/tempest/.testrepository/tmp* ]; then
|
||||
# If testr timed out, collect temp file from testr
|
||||
sudo cp $BASE/old/tempest/.testrepository/tmp* $BASE/logs/old/subunit_log.txt
|
||||
sudo gzip -9 $BASE/logs/old/subunit_log.txt
|
||||
sudo chown jenkins:jenkins $BASE/logs/old/subunit_log.txt.gz
|
||||
sudo chmod a+r $BASE/logs/old/subunit_log.txt.gz
|
||||
sudo cp $BASE/old/tempest/.testrepository/tmp* $BASE/logs/old/testrepository.subunit
|
||||
sudo gzip -9 $BASE/logs/old/testrepository.subunit
|
||||
sudo chown jenkins:jenkins $BASE/logs/old/testrepository.subunit.gz
|
||||
sudo chmod a+r $BASE/logs/old/testrepository.subunit.gz
|
||||
fi
|
||||
|
||||
if [ -f $BASE/new/tempest/tempest.log ] ; then
|
||||
|
||||
Reference in New Issue
Block a user