Question about simplestreams and imagemetadata

Scott Moser smoser at ubuntu.com
Thu Aug 8 19:56:16 UTC 2013


On Wed, 7 Aug 2013, Jeroen Vermeulen wrote:

> On 07/08/13 14:27, Scott Moser wrote:
>
> > So we went ahead and knocked off the :azure.
>
> From the product ids inside the azure.json etc. files, where the
> incompatibility happens?  Or also from the entries in the indexes?
>
> Looking at the index contents, I find the entry keys puzzling:
>
>   com.ubuntu.cloud:daily  (for Azure)
>   com.ubuntu.cloud:daily:aws  (for EC2)
>   com.ubuntu.cloud:daily:download  (for... what?)
>
> What do those ":aws" and ":download" suffixes mean, and why doesn't the Azure
> part of the index have one?

They're "content_id"s but they really dont matter at all.

You're looking for something that has data about a 'cloud' with the
endpoint and region that you're interested in, and the 'product' that
you're interested in.

>
> I tried to read the simplestreams documentation, but it's not very helpful or
> up to date.  I guess that's how the imagemetadata package and the
> simplestreams data became incompatible in the first place.

index.json contains (trimmed a bit):

"com.ubuntu.cloud:released:azure": {
   ..
   "clouds": [
    { "region": "East Asia", "endpoint": "https://management.core.windows.net/" },
    { "region": "East US 2", "endpoint": "https://management.core.windows.net/" },
    { "region": "China North", "endpoint": "https://management.core.chinacloudapi.cn/" }
   ],
   "format": "products:1.0",
   "datatype": "image-ids",
   "cloudname": "azure",
   "products": [
    "com.ubuntu.cloud:server:13.10:amd64",
     ..
    "com.ubuntu.cloud:server:12.04:amd64",
   ],
   "path": "streams/v1/com.ubuntu.cloud:released:azure.json"
  }

That tells you if you're looking for information about
'com.ubuntu.cloud:server:13.10:amd64' in cloud
{region: "East Asia", "endpoint": "https://management.core.windows.net/"}

Then you'll find that in streams/v1/com.ubuntu.cloud:released:azure.json .

Juju "knows" that it wants to find 'com.ubuntu.cloud:server:12.04:amd64'
and it "knows" the endpoints its looking for an image in.

The thing that is confusing to me here is that you're working on a
provider, but this should be completely provider generic code.



More information about the Juju-dev mailing list