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

docs: more detail about using bootc images #189

Closed
wants to merge 1 commit into from

Conversation

miabbott
Copy link
Contributor

@miabbott miabbott commented Nov 7, 2023

This adds more verbose details around composing base images, customizing images, installing images, and updating systems. It's intended to help users learning about the bootc paradigm by filling in some gaps on how to use things right now.

It's noted that this information may be out of date quickly and will likely need multiple revisions to stay current.

This adds more verbose details around composing base images,
customizing images, installing images, and updating systems. It's
intended to help users learning about the `bootc` paradigm by filling
in some gaps on how to use things right now.

It's noted that this information may be out of date quickly and will
likely need multiple revisions to stay current.
Copy link

openshift-ci bot commented Nov 7, 2023

Hi @miabbott. Thanks for your PR.

I'm waiting for a containers member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Copy link
Collaborator

@cgwalters cgwalters left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this!

possible to use [osbuild to generate disk images](https://github.com/osbuild/osbuild/pull/1418)
from a `bootc` compatible container image.

## Updating your system with `bootc`
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This section overlaps with other parts of the docs.

You'll use `bootc upgrade` to instruct the system to pull the latest version of
your compatible container image and apply it to your system.

## Switching the `bootc` compatible container image
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ditto.

use `bootc install-to-filesystem` to install the contents of the compatible
container image to an existing filesystem on a host.

These methods can be [driven interactively](https://github.com/containers/bootc/blob/main/docs/install.md#using-bootc-install-to-filesystem---replacealongside)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's make this a relative reference to just install.md.

that a user could write a cloud-config snippet to drive the `bootc` install methods on
a cloud VM that supports `cloud-init`.

**NOTE:** The current implementation of the `install` and `install-to-filesystem` methods
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can clarify this in the install.md docs instead?

The requirement for both methods is that your treefile/manifest **MUST** include
the `bootc` package in list of packages included in your compose.

## Building a custom `bootc` compatible image
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm OK with this but isn't it somewhat covered already by linking to e.g. https://github.com/coreos/layering-examples ?

(I think it'd be best to centralize that and clean it up alongside centos-boot )

Comment on lines +63 to +64
The easiest and most straight-forward way is to use `rpm-ostree compose image`
in order to produce a `bootc` compatible OCI image from a [treefile](https://coreos.github.io/rpm-ostree/treefile/)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is already linked earlier in this doc, right?

@@ -55,4 +55,79 @@ as part of your `RUN` invocations. This will perform early detection
of some incompatibilities but is not a strict requirement today and will not be
in the future.

# Building and using `bootc` compatible images in the real world
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I understand the sentiment but...overall ISTM we should try to improve the existing bits of the docs to match the "real world"

Comment on lines +74 to +75
The requirement for both methods is that your treefile/manifest **MUST** include
the `bootc` package in list of packages included in your compose.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree this bit should be clearer.

@cgwalters
Copy link
Collaborator

Maybe the biggest problem is that this base images doc happens to be ordered first, but should probably be last?

Certainly a core tension running through this too is actually I think it'd be most useful to improve the centos-boot docs; started on that in CentOS/centos-bootc#33
Because this project is distribution independent and it's ok to have some references to dnf and Anaconda, but in the end those things are best in the OS/distro docs.

@vrothberg
Copy link
Member

Certainly a core tension running through this too is actually I think it'd be most useful to improve the centos-boot docs; started on that in CentOS/centos-boot#33

I think that as many docs as possible should be moved here to bootc. At the moment, it's the core and the other bits are moving a lot (see the recent renaming).

Because this project is distribution independent and it's ok to have some references to dnf and Anaconda, but in the end those things are best in the OS/distro docs.

Agreed that distro-specific things should be mentioned in the distro docs. For the rest, I'd prefer if the distros just point to the docs here to avoid redundancy and divergence. bootc docs could point to the individual distros and images.

@miabbott
Copy link
Contributor Author

miabbott commented Nov 8, 2023

@cgwalters @vrothberg My intent was to provide a detailed description of the various phases of a building/using a compatible image using real world examples, based on the feedback from internal chat. I knew submitting this was going to duplicate some of existing docs, but I wanted gather more feedback on how best to structure this and where it should live.

I'll clean up the PR based on the comments so far...if you have additional thoughts/guidance on how to approach telling this narrative or where it should live, please continue to share!

Copy link
Collaborator

@cgwalters cgwalters left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Marking PR state

@miabbott
Copy link
Contributor Author

As I started to address the feedback, the original intent of this PR drifted. I'll open a replacement PR shortly.

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

Successfully merging this pull request may close these issues.

None yet

3 participants