# FIXME: must not add development builds... or maybe?
# cidb wise, we only care about builds from master, hotfix + develop
if GIT_BRANCH_NAME == 'master' or GIT_BRANCH_NAME == 'develop' or GIT_BRANCH_NAME.startswith('hotfix/'):
+ package_instances=[]
try:
- package_instance_id = add_package_instance("profitbricks", BUILD_JOBNAME, BUILD_NUMBER, changes_file, version, BUILD_START, BUILD_END)
+ package_instances.append(add_package_instance("profitbricks", BUILD_JOBNAME, BUILD_NUMBER, changes_file, version, BUILD_START, BUILD_END))
except Exception, error:
cmd = ['figlet-figlet', '-t', 'package instance not added to DB']
subprocess.check_call(cmd)
#FIXME: this should really cause an error
# exit_error()
- #add_liveboot_request(package_instance_id)
-
+ if len(package_instances) > 0:
+ try:
+ add_liveboot_request(package_instances)
+ except:
+ logger.debug("liveboot request failed")
# finally
exit_ok()