Update the buildman with the database job config post merge with nomenclature.
This commit is contained in:
parent
ed28bdb28b
commit
fd825b82cd
1 changed files with 3 additions and 5 deletions
|
@ -19,9 +19,7 @@ class BuildJob(object):
|
||||||
)
|
)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
self._repo_build = model.get_repository_build(self._job_details['namespace'],
|
self._repo_build = model.get_repository_build(self._job_details['build_uuid'])
|
||||||
self._job_details['repository'],
|
|
||||||
self._job_details['build_uuid'])
|
|
||||||
except model.InvalidRepositoryBuildException:
|
except model.InvalidRepositoryBuildException:
|
||||||
raise BuildJobLoadException(
|
raise BuildJobLoadException(
|
||||||
'Could not load repository build with ID %s' % self._job_details['build_uuid'])
|
'Could not load repository build with ID %s' % self._job_details['build_uuid'])
|
||||||
|
@ -38,8 +36,8 @@ class BuildJob(object):
|
||||||
# TODO(jschorr): Change this to use the more complicated caching rules, once we have caching
|
# TODO(jschorr): Change this to use the more complicated caching rules, once we have caching
|
||||||
# be a pull of things besides the constructed tags.
|
# be a pull of things besides the constructed tags.
|
||||||
tags = self._build_config.get('docker_tags', ['latest'])
|
tags = self._build_config.get('docker_tags', ['latest'])
|
||||||
existing_tags = model.list_repository_tags(self._job_details['namespace'],
|
existing_tags = model.list_repository_tags(self._repo_build.repository.namespace_user.username,
|
||||||
self._job_details['repository'])
|
self._repo_build.repository.name)
|
||||||
|
|
||||||
cached_tags = set(tags) & set([tag.name for tag in existing_tags])
|
cached_tags = set(tags) & set([tag.name for tag in existing_tags])
|
||||||
if cached_tags:
|
if cached_tags:
|
||||||
|
|
Reference in a new issue