Skip to content

Commit

Permalink
Insert generated image.json into the ostree commit [retry]
Browse files Browse the repository at this point in the history
Retry landing this since a followup commit should fix AWS replication.

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
  • Loading branch information
cgwalters committed May 4, 2022
1 parent 0fd8955 commit 0a878e8
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/cosalib/qemuvariants.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,9 @@ def __init__(self, **kwargs):

_Build.__init__(self, **kwargs)

repo = os.path.join(self._workdir, 'tmp/repo')
import_ostree_commit(repo, self._tmpdir, self.meta)

@property
def image_qemu(self):
"""
Expand Down

0 comments on commit 0a878e8

Please sign in to comment.