canonical/pylxd

Are there any plans to support simplestream in pylxd

fliiiix opened this issue · 0 comments

Reason for this is the official mirror is simple stream

see this example which fails:

import pylxd

def __get_remote_image_fingerprint(remote, image_name):
    image_fingerprint = image_name
    if remote:
        remote_client = pylxd.Client(remote)
    else:
        remote_client = pylxd.Client()
    if remote_client.images.exists(image_name, alias=True):
        image_fingerprint = remote_client.images.get_by_alias(image_name).fingerprint
    else:
        if not remote_client.images.exists(image_name):
            raise LxdImageNotFoundError(
                "Image '{}' not found on server '{}'".format(image_name, remote)
            )
    return image_fingerprint


remote = "https://images.linuxcontainers.org"
image_name = "debian/buster/i386"

__get_remote_image_fingerprint(remote, image_name)

And https://discuss.linuxcontainers.org/t/problem-with-the-uk-mirror/12632 for more context