Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support ostree native containers (container as OS) #300

Open
garrett opened this issue Dec 6, 2022 · 4 comments
Open

support ostree native containers (container as OS) #300

garrett opened this issue Dec 6, 2022 · 4 comments

Comments

@garrett
Copy link
Member

garrett commented Dec 6, 2022

Details: https://coreos.github.io/rpm-ostree/container/

rpm-ostree inherits work in ostree-rs-ext to create “container native ostree” functionality. This elevates OCI/docker containers to be natively supported as a transport mechanism for bootable operating systems.

Support is already available as of Fedora 36. It's still being worked on. They may switch to using it as the default format for Fedora 38.

Related, but a little different: https://github.com/containers/bootc (we'll likely keep our integration point at rpm-ostree)

@garrett
Copy link
Member Author

garrett commented Dec 7, 2022

https://github.com/coreos/enhancements/blob/main/os/coreos-layering.md#existing-work

Specifically as of today, this functionality is exposed in:

  • rpm-ostree ex-container
  • rpm-ostree rebase --experimental $containerref

HOWEVER, according to https://coreos.github.io/rpm-ostree/container/ it's even easier, perhaps?

Rebasing a client system

Use this to switch to booting from a container image:

$ rpm-ostree rebase ostree-unverified-registry:quay.io/fedora/fedora-coreos:stable

And:

After a rebase, all further rpm-ostree operations work as you’d expect. For example, rpm-ostree upgrade will look for a new container version. You can also rpm-ostree apply-live, etc. It also does still work to do “client side” rpm-ostree install etc.
...

@garrett
Copy link
Member Author

garrett commented Dec 7, 2022

Jorge Castro made a video to demonstrate this yesterday:

https://www.youtube.com/watch?v=X8h304Jp9N8

@garrett
Copy link
Member Author

garrett commented Dec 7, 2022

OK, I think all we'd need to support it in cockpit-ostree right now is a toggle (off by default) to support --experimental during rebases. And then remember the experimental state for the repo when rebasing back to it (after rebasing to something else).

And when this isn't deemed "experimental" (probably in F38?) then it's probably not even needed. Although other "experiments" could possibly show up in the future.

If we could somehow detect the experimental repos or just always turn it on, we wouldn't even need the flag and just transparently support it.


Building on this, we could try a rebase, catch an error, and have a modal that says something about the container format is not supported by default, but is an experimental format and ask to proceed.

I think this would be even better than having an experimental toggle, IMO. And it should be more future proof and the UI wouldn't be seen in F38 and beyond (unless they add another source type afterward).

@garrett
Copy link
Member Author

garrett commented Dec 13, 2022

Curated lists of examples of custom images for OStree native container images @ https://github.com/ublue-os/awesome-custom-images

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant