Fedora CI: Publish the mock logs even when it fails

This commit is contained in:
Miro Hrončok 2019-09-18 17:09:03 +02:00
parent d262d909f5
commit 7e01f58f73

View File

@ -23,14 +23,17 @@ spectool -g -R ${1}.spec
rpmbuild -bs ${1}.spec
# build the SRPM in mock
res=0
mock -r $config --enablerepo=local init
mock -r $config --enablerepo=local ~/rpmbuild/SRPMS/${1}-*.src.rpm
mock -r $config --enablerepo=local ~/rpmbuild/SRPMS/${1}-*.src.rpm || res=$?
# move the results to the artifacts directory, so we can examine them
artifacts=${TEST_ARTIFACTS:-/tmp/artifacts}
pushd /var/lib/mock/fedora-rawhide-x86_64/result
mv *.rpm ${artifacts}/
mv *.rpm ${artifacts}/ || :
for log in *.log; do
mv ${log} ${artifacts}/${1}-${log}
done
popd
exit $res