Add labeling of built manifests with their build IDs

Also sends the digests to the notification

Fixes #593
This commit is contained in:
Joseph Schorr 2016-09-12 15:30:15 -04:00
parent 2b00c644b5
commit 02b8afe127
3 changed files with 27 additions and 3 deletions

View file

@ -32,7 +32,7 @@ class BuildJob(object):
def has_retries_remaining(self):
return self.job_item.retries_remaining > 0
def send_notification(self, kind, error_message=None, image_id=None):
def send_notification(self, kind, error_message=None, image_id=None, manifest_digests=None):
tags = self.build_config.get('docker_tags', ['latest'])
event_data = {
'build_id': self.repo_build.uuid,
@ -46,6 +46,9 @@ class BuildJob(object):
if image_id is not None:
event_data['image_id'] = image_id
if manifest_digests:
event_data['manifest_digests'] = manifest_digests
if error_message is not None:
event_data['error_message'] = error_message