fedimg: patch to process the F28+ messages
Signed-off-by: Sayan Chowdhury <sayan.chowdhury2012@gmail.com>
This commit is contained in:
parent
628906a945
commit
586b46910d
1 changed files with 18 additions and 9 deletions
|
@ -80,15 +80,24 @@ class FedimgConsumer(fedmsg.consumers.FedmsgConsumer):
|
||||||
|
|
||||||
location = msg_info['location']
|
location = msg_info['location']
|
||||||
compose_id = msg_info['compose_id']
|
compose_id = msg_info['compose_id']
|
||||||
compose_metadata = fedfind.release.get_release_cid(compose_id).metadata
|
compose_metadata = fedfind.release.get_release(cid=compose_id).metadata
|
||||||
|
|
||||||
|
# Till F27, both cloud-base and atomic images were available
|
||||||
|
# under variant CloudImages. With F28 and onward releases,
|
||||||
|
# cloud-base image compose moved to cloud variant and atomic images
|
||||||
|
# moved under atomic variant.
|
||||||
|
prev_rel = ['26', '27']
|
||||||
|
if msg_info['release_version'] in prev_rel:
|
||||||
images_meta = get_value_from_dict(
|
images_meta = get_value_from_dict(
|
||||||
compose_metadata,
|
compose_metadata, 'images', 'payload', 'images', 'CloudImages',
|
||||||
'images',
|
'x86_64')
|
||||||
'payload',
|
else:
|
||||||
'images',
|
images_meta = get_value_from_dict(
|
||||||
'CloudImages',
|
compose_metadata, 'images', 'payload', 'images',
|
||||||
'x86_64'
|
'Cloud', 'x86_64')
|
||||||
)
|
images_meta.extend(get_value_from_dict(
|
||||||
|
compose_metadata, 'images', 'payload',
|
||||||
|
'images', 'AtomicHost', 'x86_64'))
|
||||||
|
|
||||||
if images_meta is None:
|
if images_meta is None:
|
||||||
LOG.debug('No compatible image found to process')
|
LOG.debug('No compatible image found to process')
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue