jenkins-run script: implement retrying functionality.

The aim is to rerun buildout on certain conditions, such as network problems.