Skip to content

Commit 32aef4e

Browse files
committed
docs: Add experimental section for bound images
Signed-off-by: Chris Kyrouac <[email protected]>
1 parent 934cc88 commit 32aef4e

File tree

2 files changed

+36
-0
lines changed

2 files changed

+36
-0
lines changed

docs/src/SUMMARY.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@
4747
# Experimental features
4848

4949
- [bootc image](experimental-bootc-image.md)
50+
- [logically bound images](experimental-logically-bound-images.md)
5051

5152
# More information
5253

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# Logically Bound Images
2+
3+
Experimental features are subject to change or removal. Please
4+
do provide feedback on them.
5+
6+
Tracking issue: <https://github.com/containers/bootc/issues/128>
7+
8+
## About logically bound images
9+
10+
This experimental feature enables an association of container "app" images to a bootc system image. A similar approach to this is [physically bound](https://github.com/containers/bootc/issues/644) images. There are some trade-offs between the two approaches. Some benefits of logically bound images are:
11+
12+
- The bootc system image can be updated without re-downloading the app image bits.
13+
- The app images can be updated without modifying the bootc system image, this would be especially useful for development work
14+
15+
## Using logically bound images
16+
17+
Each image is defined in a [Podman Quadlet](https://docs.podman.io/en/latest/markdown/podman-systemd.unit.5.html) `.image` or `.container` file. An image is selected to be bound by creating a symlink in the `/usr/lib/bootc-experimental/bound-images.d` directory pointing to a `.image` or `.container` file. With these defined, during a `bootc upgrade` or `bootc switch` the bound images defined in the new bootc image will be automatically pulled via podman.
18+
19+
An example Containerfile
20+
21+
```Dockerfile
22+
FROM quay.io/myorg/myimage:latest
23+
24+
COPY ./my-app.image /usr/share/containers/systemd/my-app.image
25+
COPY ./another-app.container /usr/share/containers/systemd/another-app.container
26+
27+
RUN ln -s /usr/share/containers/systemd/my-app.image /usr/lib/bootc-experimental/bound-images.d/my-app.image && \
28+
ln -s /usr/share/containers/systemd/my-app.image /usr/lib/bootc-experimental/bound-images.d/my-app.image
29+
```
30+
31+
## Limitations
32+
33+
- Currently, only the Image field of a `.image` or `.container` file is used to pull the image. Any other field is ignored.
34+
- There is no cleanup during rollback.
35+
- Images are subject to default garbage collection semantics; e.g. a background job pruning images without a running container may prune them. They can also be manually removed via e.g. podman rmi.

0 commit comments

Comments
 (0)