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

Insert generated image.json into the ostree commit [retry] #2839

Merged
merged 1 commit into from
Jun 1, 2022

Conversation

cgwalters
Copy link
Member

@cgwalters cgwalters commented May 3, 2022

This is part of coreos/fedora-coreos-tracker#1151

Our generated disk images are largely just a "shell" around the egg
of an ostree commit. There is almost nothing that lives
in the disk image that isn't in the commit.

(This is especially true now that a preparatory commit previous to
this moved the content of our static grub.cfg into image.json)

In the original coreos-assembler design I'd tried to cleanly
separate builds of the ostree from disk image builds, but also
support linking them together (with matching version numbers, etc.)
The separate image.yaml was part of this. This...mostly worked.

This change furthers that separation by having image builds input from
just the ostree commit. Crucially we would no longer need the config
git repository to perform an image build.

And this in turn unlocks truly better separating ostree builds from
disk image builds in the pipeline and supporting
downstream tooling generating disk images from custom containers.

One neat thing here is we will finally fix a longstanding issue
where coreos-assembler fails when just the image.yaml changes:

Closes: #972


@cgwalters cgwalters changed the title qemuvariants: Extract ostree repo in mutate image, not class init Insert generated image.json into the ostree commit [retry] May 4, 2022
@cgwalters
Copy link
Member Author

We can give this one another try right?

@dustymabe
Copy link
Member

We can give this one another try right?

Let's discuss with @jlebon when he is back (maybe tomorrow?).

@cgwalters
Copy link
Member Author

Any updates on this?

Copy link
Member

@dustymabe dustymabe left a comment

Choose a reason for hiding this comment

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

Sorry about the delay here.. Did an initial round of review.

src/cmd-buildextend-metal Outdated Show resolved Hide resolved
src/cmd-buildextend-metal Outdated Show resolved Hide resolved
src/cmdlib.sh Show resolved Hide resolved
src/cosalib/cmdlib.py Outdated Show resolved Hide resolved
src/cosalib/qemuvariants.py Outdated Show resolved Hide resolved
src/cmdlib.sh Show resolved Hide resolved
src/cosalib/qemuvariants.py Outdated Show resolved Hide resolved
@cgwalters
Copy link
Member Author

OK, squashed the fixup commit now that it's passed CI.

jlebon
jlebon previously approved these changes May 31, 2022
@jlebon
Copy link
Member

jlebon commented May 31, 2022

/test rhcos

@cgwalters
Copy link
Member Author

flaked on coreos/fedora-coreos-tracker#1214
/override ci/prow/rhcos

@openshift-ci
Copy link

openshift-ci bot commented May 31, 2022

@cgwalters: Overrode contexts on behalf of cgwalters: ci/prow/rhcos

In response to this:

flaked on coreos/fedora-coreos-tracker#1214
/override ci/prow/rhcos

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.

This is part of coreos/fedora-coreos-tracker#1151

Our generated disk images are largely just a "shell" around the egg
of an ostree commit.  There is almost nothing that lives
in the disk image that isn't in the commit.

(This is especially true now that a preparatory commit previous to
 this moved the *content* of our static `grub.cfg` into `image.json`)

In the original coreos-assembler design I'd tried to cleanly
separate builds of the ostree from disk image builds, but also
support linking them together (with matching version numbers, etc.)
The separate `image.yaml` was part of this.  This...mostly worked.

This change furthers that separation by having image builds input from
*just the ostree commit*.  Crucially we would no longer need the config
git repository to perform an image build.

And this in turn unlocks truly better separating ostree builds from
disk image builds in the pipeline *and* supporting
downstream tooling generating disk images from custom containers.

One neat thing here is we will finally fix a longstanding issue
where coreos-assembler fails when just the `image.yaml` changes:

Closes: coreos#972
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

Successfully merging this pull request may close these issues.

RHCOS pipeline fails if just image.yaml changes
3 participants