Skip to content

Add support for bootc install --with-overlay quay.io/exampleuser/someoverlay:latest #190

Open
@cgwalters

Description

@cgwalters

I've been advocating general configmap and secret support for a while.

However, the way CoreOS does things today with Ignition is basically allowing the admin to inject "day 1 unmanaged state" that is decoupled from the image/host. And actually, that's how Anaconda kickstart works too.

There's a lot of advantages to configmap-in-registry around supporting "day 2" changes too. However, it will require workflow and tooling changes to adapt.

One key thing I'm narrowing in on is the basic use case of "inject a ssh key into an existing golden image" - a thing I think we really want to support. And we do today via e.g. Anaconda or other installers.

But I think we should support this more natively via bootc install too.

So here's my strawman: the --with-overlay argument takes a container image reference and operates only at install time. A very key difference from the configmap approach is that the image must drop files into /etc and /var. This gives us immediate, direct support for SSH keys by injecting e.g. /var/roothome/.ssh/authorized_keys.

Migrating from Ignition

But actually the neat thing with this is it provides a very seamless adaptation of existing Ignition configuration! We've already prototyped out support for extracting an Ignition configuration to its set of files via ignition-apply, so it'd literally look like:

FROM quay.io/coreos/butane:release as builder
COPY foo.ign foo.ign
RUN ignition-apply --root /config foo.ign # render ignition to filesystem tree, error on partitioning

FROM scratch
COPY --from=builder /config /

Then push that to a registry as quay.io/exampleuser/someoverlay:latest, and one can do bootc install --with-overlay quay.io/exampleuser/someoverlay:latest and then one can switch to installing via bootc without needing to change all the bits in the Ignition config to move to /usr content etc.

So any tools (e.g. OpenShift MCO) that act on "day 2" management for this "unmanaged state" can seamlessly continue to work - but we avoid the need to e.g. host Ignition servers.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/configRelated to configurationarea/installIssues related to `bootc install`enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions