buildpacks / lifecycle

Reference implementation of the Cloud Native Buildpacks lifecycle
https://buildpacks.io
Apache License 2.0
186 stars 105 forks source link

Feature Request: Support exporting images to a containerd socket #829

Open spkane opened 2 years ago

spkane commented 2 years ago

Description

It is more and more common not to have a local Docker daemon available and during certain testing cycles pushing to a registry is not always easy or desirable.

It would be great if you could easily create a buildpack and then export the results directly into a containerd namespace.

Proposed solution

Extend pack and the underlying creator command so that it is possible to pass in something like -containerd k8s.io, which will then tell the export step to push the results into that containerd namespace instead of into a Docker registry or daemon.

Describe alternatives you've considered

Many hacks that require running Docker, exporting to docker, pull out the image, and then re-pushing it into containerd.

spkane commented 2 years ago

Cross-posted here: https://github.com/buildpacks/pack/issues/1393

Feel free to close one or the other, but I wasn't sure which location was best, and whether both tools would need related changes.

jjbustamante commented 2 years ago

Hi @spkane, Thanks for creating the issue! I've been working on a couple of RFCs related to adding additional support for removing the Daemon or exporting to OCI format.

I will try to take this issue into the evaluation and see if we can move forward with the idea!

spkane commented 2 years ago

Thank you very much @jjbustamante ! That would be very much appreciated.

natalieparellano commented 1 year ago

With export to OCI layout supported in lifecycle 0.17.0, this is no longer blocked. We should research if we can use OCI layout as intermediate glue to export to the containerd socket. This research would probably need to be done in partnership with some folks from pack.

natalieparellano commented 1 year ago

cc @jjbustamante

natalieparellano commented 10 months ago

See https://github.com/buildpacks/pack/issues/1519#issuecomment-1808518168 - we have a short-term hack that degrades performance, but refactoring imgutil/local to use imgutil/layout/sparse will solve this cleanly.

jjbustamante commented 10 months ago

See buildpacks/pack#1519 (comment) - we have a short-term hack that degrades performance, but refactoring imgutil/local to use imgutil/layout/sparse will solve this cleanly.

Do we need to fix this issue first?