Re: [BuildStream] Proposal: OCI image source plugin



Hi,

A quick pointer for consideration: https://blog.docker.com/2018/04/docker-registry-api-standardized-oci/.

Cheers,

Sander

On Wed, Oct 10, 2018, 11:37 Daniel Silverstone via BuildStream-list <buildstream-list gnome org> wrote:
Summary
=======

I'd like to propose that we add a Source plugin which is capable of reading OCI
images either from URL or local filesystem and providing their unpacked content
as the source for an element.  I seek input from anyone who has looked at OCI
images and knows of any pitfalls or risks which would need to be taken into
account.

Background
==========

The [Open Containers Initiative][oci] define [a format for specifying container
images][ociimg].  This is essentially the same as a docker image or somesuch,
but is self-contained (all layers are part of the same deliverable binary) and
has some metadata on how to put it together.

It would be helpful to be able to consume these images as sysroots for use with
BuildStream.

Unfortunately OCI don't define a registry interface and as such we can only
consider OCI images coming from basic URLs and/or from the filesystem.

Rough implementation plan
=========================

The intent would be to create a Source plugin similar to the TarSource or
DebSource plugins.  This would take a url or filepath and a sha256sum of it
as the ref, along with an optional directory to extract into.

Rather than relying on any external implementations, the intention would be
to implement an OCI image reader as part of the plugin in pure Python.

Note: There is no expectation of supporting an external blob store, and as
such, the plugin will only be able to handle integral image files which contain
all relevant images.  It's also worth noting that OCI images can specify
support for multiple architectures, and that may need attention as and when
BuildStream comes to understand and support multiple architectures.


[oci]: https://pbs.twimg.com/media/DpG9EXFXgAABfBk.jpg:large
[ociimg]: https://github.com/opencontainers/image-spec

Thanks,

Daniel.

--
Daniel Silverstone                          https://www.codethink.co.uk/
Solutions Architect               GPG 4096/R Key Id: 3CCE BABE 206C 3B69
_______________________________________________
BuildStream-list mailing list
BuildStream-list gnome org
https://mail.gnome.org/mailman/listinfo/buildstream-list
--

Cheers,

Sander


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]