You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bootc install and install-to-filesystem currently rely on the fact that they
run inside a podman container. That's quite inconvenient for using bootc
for osbuild, because osbuild already run everything in a container.
While having a container in a container is surely possible, it gets quite
messy.
Instead of going this route, this commit implements a new --source-imgref
argument. --source-imgref accepts a container image reference (the same one
that skopeo uses). When --source-imgref is used, bootc doesn't escape the
container to fetch the container image from host's container storage. Instead,
the container image given by --source-imgref is used.
Even when running in this mode, bootc needs to run in a container created from
the same container image that is passed using --source-imgref. However, this
isn't a problem to do in osbuild. This really just removes the need for bootc
to escape the container to the host mount namespace.
Signed-off-by: Ondřej Budai <[email protected]>
Copy file name to clipboardExpand all lines: docs/install.md
+15Lines changed: 15 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -234,3 +234,18 @@ At the current time, leftover data in `/` is **NOT** automatically cleaned up.
234
234
be useful, because it allows the new image to automatically import data from the previous
235
235
host system! For example, things like SSH keys or container images can be copied
236
236
and then deleted from the original.
237
+
238
+
### Using `bootc install to-filesystem --source-imgref <imgref>`
239
+
240
+
By default, `bootc install` has to be run inside a podman container. With this assumption,
241
+
it can escape the container, find the source container image (including its layers) in
242
+
the podman's container storage and use it to create the image.
243
+
244
+
When `--source-imgref <imgref>` is given, `bootc` no longer assumes that it runs inside podman.
245
+
Instead, the given container image reference (see [containers-transports(5)](https://github.com/containers/image/blob/main/docs/containers-transports.5.md)
246
+
for accepted formats) is used to fetch the image. Note that `bootc install` still has to be
247
+
run inside a chroot created from the container image. However, this allows users to use
248
+
a different sandboxing tool (e.g. [bubblewrap](https://github.com/containers/bubblewrap)).
249
+
250
+
This argument is mainly useful for 3rd-party tooling for building disk images from bootable
251
+
containers (e.g. based on [osbuild](https://github.com/osbuild/osbuild)).
0 commit comments