Add `bootc container export --format=tar`
- Dominant language
- Rust
- Stars
- 2.3k
- Forks
- 230
- Avg merge
- 3d 12h
- Merged PRs (30d)
- 38
Description
This relates a bit to https://github.com/bootc-dev/bootc/issues/898 - but it's for people who want to use bootc-oriented containers with e.g. the [`liveimg` verb of Anaconda](https://docs.redhat.com/en/documentation/red_hat_enterprise_linux/9/html/automatically_installing_rhel/kickstart-commands-and-options-reference_rhel-installer#liveimg_kickstart-commands-for-installation-program-configuration-and-flow-control) and similar things.
What I'm thinking here is we have `bootc container export [--experimental]` that is usable like this:
```
podman run --rm --mount=type=image,source=,target=/target
bootc container export /target > output.tar` or so.
```
## What does this do beyond just `tar -cf - /target`?
- SELinux labeling as if it was a booted host
- Possibly adjusting (for legacy compatibility) by writing the kernel into `/boot` in the tar stream instead of `/usr/lib/modules`
And maybe more things - but those two are important.
Contributor guide
Assessment
This issue has not been assessed yet.