Use simplestreams rather than hardcoding amis

Bug #1401172 reported by Martin Packman
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
juju-ci-tools
Fix Released
High
Seman

Bug Description

A few places in juju-ci-tools code and jenkins jobs hardcode ami ids, which means we are often using images several months out of date.

We have simplestreams data published with up to date images for all clouds, we should use the simplestreams library/tool to pick the latest one each time.

Revision history for this message
Curtis Hovey (sinzui) wrote :

This command queries cloud-images at ec2.us-east-1.amazonaws.com like amd64 trusty hvm ebs. The listing of pubname and ami show the matching image and its AMI id. We want the newest image. I think we can concert the output to a list, sort it, them pop the newest one. We can do this in a python script. we want the script to take the 'series' and 'arch' params as options so that we can use it in many tests.

sstream-query http://cloud-images.ubuntu.com/releases/streams/v1/index.json endpoint~ec2.us-east-1.amazonaws.com arch=amd64 release=trusty label=release virt=hvm root_store=ebs --output-format "%(pubname)s %(id)s"

ubuntu-trusty-14.04-amd64-server-20150305 ami-6889d200
ubuntu-trusty-14.04-amd64-server-20150227.2 ami-a6b8e7ce
ubuntu-trusty-14.04-amd64-server-20150225.2 ami-0cc79a64
ubuntu-trusty-14.04-amd64-server-20150209.1 ami-08f8b160
ubuntu-trusty-14.04-amd64-server-20150123 ami-86562dee
ubuntu-trusty-14.04-amd64-server-20141125 ami-76e27e1e
ubuntu-trusty-14.04-amd64-server-20140927 ami-9aaa1cf2
ubuntu-trusty-14.04-amd64-server-20140926 ami-0c70c464
ubuntu-trusty-14.04-amd64-server-20140924 ami-fc338694
ubuntu-trusty-14.04-amd64-server-20140923 ami-8afb51e2
ubuntu-trusty-14.04-amd64-server-20140829 ami-1a389d72
ubuntu-trusty-14.04-amd64-server-20140816 ami-acff23c4
ubuntu-trusty-14.04-amd64-server-20140813 ami-cc4d9fa4
ubuntu-trusty-14.04-amd64-server-20140724 ami-b227efda
ubuntu-trusty-14.04-amd64-server-20140607.1 ami-588c7f30
ubuntu-trusty-14.04-amd64-server-20140528 ami-cccf3ba4
ubuntu-trusty-14.04-amd64-server-20140416.1 ami-1d8c9574

Revision history for this message
Curtis Hovey (sinzui) wrote :

The simple-streams package provides the sstream-query command. If we install python-simplestreams, we can import the simplestreams lib.

Curtis Hovey (sinzui)
Changed in juju-ci-tools:
importance: Low → High
assignee: nobody → Seman (sseman)
Seman (sseman)
Changed in juju-ci-tools:
status: Triaged → Fix Committed
Curtis Hovey (sinzui)
Changed in juju-ci-tools:
status: Fix Committed → In Progress
Seman (sseman)
Changed in juju-ci-tools:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.