From: Mathias Klette Date: Fri, 7 Jun 2013 10:00:27 +0000 (+0200) Subject: debian_build: show help instructions for chroot debugging on either case (success... X-Git-Url: https://git.uhu-banane.de/?a=commitdiff_plain;h=ccc08757f6ed8ba2ceac21cd12ebaa0d82a2e442;p=profitbricks%2Fjenkins-build-scripts.git debian_build: show help instructions for chroot debugging on either case (success AND error) --- diff --git a/debian_build.py b/debian_build.py index 21fce2e..ea7b2b9 100755 --- a/debian_build.py +++ b/debian_build.py @@ -450,12 +450,17 @@ if __name__ == '__main__': # .. now handle the result if ret: + logger.error('git-buildpackage failed with exitcode {code}'.format(code=ret)) figlet('Build failed') - logger.error('''git-buildpackage failed with exitcode {code} + exit_error() + else: + figlet('Build OK') + + logger.info(''' ### -### In case you need to analyze errors within chroot, do the following: +### In case you need to analyze the results within chroot, do the following: ### * login to {hostname} -### * become {jenkins_user} +### * become user {jenkins_user} ### * then execute: ### @@ -466,7 +471,6 @@ export {gbp_env} FORCE_SHELL=TRUE ### ### '''.format( - code=ret, hostname=socket.gethostname(), jenkins_user=ENV['USER'], jenkins_workspace=ENV['WORKSPACE'], @@ -475,10 +479,6 @@ export {gbp_env} FORCE_SHELL=TRUE ]), command=' '.join(gbp.command), )) - exit_error() - else: - figlet('Build OK') - # # ACT V: post-build actions #