Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
live: mount ISO squashfs directly out of the rootfs image
cosa now uses identical initramfs and rootfs images in the PXE and ISO artifacts. Instead of expecting /root.squashfs, find the rootfs image in the ISO pxeboot directory and mount the squashfs from a fixed offset in the cpio archive. Use the existence of the coreos.liveiso= karg, rather than a flag file, to detect that we're ISO-booted. In ISO mode, use bsdtar to read the osmet files out of the rootfs image.
- Loading branch information
Showing
5 changed files
with
32 additions
and
13 deletions.
There are no files selected for viewing
15 changes: 15 additions & 0 deletions
15
overlay.d/05core/usr/lib/dracut/modules.d/20live/coreos-liveiso-persist-osmet.service
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| [Unit] | ||
| Description=Persist osmet files (ISO) | ||
| DefaultDependencies=false | ||
| ConditionPathExists=/run/ostree-live | ||
| ConditionKernelCommandLine=coreos.liveiso | ||
| RequiresMountsFor=/run/media/iso | ||
| Before=initrd-switch-root.target | ||
|
|
||
| [Service] | ||
| Type=oneshot | ||
| RemainAfterExit=yes | ||
| ExecStart=/usr/bin/mkdir -p /run/coreos-installer/osmet | ||
| # bsdtar reads cpio archives, and unlike cpio(1L), knows how to seek over | ||
| # members it isn't reading | ||
| ExecStart=/usr/bin/bsdtar -x -C /run/coreos-installer/osmet -f /run/media/iso/images/pxeboot/rootfs.img *.osmet |
4 changes: 3 additions & 1 deletion
4
.../20live/coreos-live-persist-osmet.service → ...live/coreos-livepxe-persist-osmet.service
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters