Script for getting the latest image of specified type from ImageFactory
AbandonedPublic

Authored by jskladan on Dec 16 2015, 1:03 PM.

Details

Summary

Once built via trigger_build, you can search for the latest image of a specified version/flavor/arch,
using the get_latest_image.py
Before the bug in ImageFactory preventing direct download of an image is fixed, the tool just returns
the ImageFactory's URL pointing to the right image

Example usage:

get_latest_image.py get --version 23
get_latest_image.py get --version 23 --flavor minimal --arch x86_64

At the moment, the code just returns an URL pointing to the right image in Imagefactory, as the image can not really be downloaded through the REST API at the moment (https://github.com/redhat-imaging/imagefactory/issues/360)

Test Plan

Tested locally against images built with trigger_build.py

Diff Detail

Lint
Lint Skipped
Unit
Unit Tests Skipped
jskladan retitled this revision from to Script for getting the latest image of specified type from ImageFactory.Dec 16 2015, 1:03 PM
jskladan updated this object.
jskladan edited the test plan for this revision. (Show Details)
jskladan added a project: libtaskotron.
tflink accepted this revision.Dec 17 2015, 7:21 AM

This looks right but I'm having trouble with this script actually working. However, I suspect that's because I've been hacking at my local instance and the enpoint operation is a bit wonky.

Assuming this has been tested reasonably well, it looks good to me. We can tweak the actual download once imagefactory's api is fixed (planning to submit a PR tomorrow or Friday).

This revision is now accepted and ready to land.Dec 17 2015, 7:21 AM

Just a tiny nitpick - get sub-command seems a bit too vague to me. Would it be clearer to have url and download sub-commands, the first one printing out the url, and the second one downloading the image immediately?

jskladan abandoned this revision.Feb 8 2016, 8:43 AM