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
The bootc project suggests that Linux operating systems and distributions
30
-
to provide a new kind of "bootable" base image, distinct from "application"
31
-
base images. See below for available images.
32
-
33
-
Effectively, these images contain a Linux kernel - and while this kernel
34
-
is not used when the image is used via e.g. `podman|docker run`, it *is*
35
-
used when booted via `bootc`.
36
-
37
-
In the current defaults, `/etc` and `/var` both act a bit like
38
-
mounted, persistent volumes. More on this in [the ostree docs](https://ostreedev.github.io/ostree/adapting-existing/#system-layout).
39
-
40
-
## Status
41
-
42
-
The core `bootc update` functionality is really just the same
43
-
technology which has shipped for some time in rpm-ostree so there
44
-
should be absolutely no worries about using it for OS updates.
45
-
A number of people do this today.
46
-
47
-
That said bootc is in active development and some parts
48
-
are subject to change, such as the command line interface and
49
-
the CRD-like API exposed via `bootc edit`.`
50
-
51
-
The `bootc install` functionality is also more experimental.
52
-
53
-
## Using bootc
54
-
55
-
### Installing
56
-
57
-
* Fedora: [bootc is packaged](https://bodhi.fedoraproject.org/updates/?packages=bootc) and be available in the main repositories soon.
58
-
* CentOS Stream 9: There is a [COPR](https://copr.fedorainfracloud.org/coprs/rhcontainerbot/bootc/) tracking git main with binary packages.
59
-
60
-
You can also build this project like any other Rust project, e.g. `cargo build --release` from a git clone.
61
-
62
-
### Base images
63
-
64
-
Many users will be more interested in base (container) images.
65
-
66
-
To build base images "from scratch", see [docs/bootc-images.md](docs/bootc-images.md).
67
-
68
-
For pre-built base images:
69
-
70
-
*[Fedora CoreOS](https://quay.io/repository/fedora/fedora-coreos) can be used as a base image; you will need to [enable bootc](https://github.com/coreos/rpm-ostree/blob/main/docs/bootc.md) there.
71
-
* There is also an in-development [Project Sagano](https://github.com/centos/sagano) for Fedora/CentOS.
72
-
73
-
However, bootc itself is not tied to Fedora derivatives; [this issue](https://github.com/coreos/bootupd/issues/468) tracks the main blocker for other distributions.
74
-
75
-
### Deriving from and switching to base images
76
-
77
-
A toplevel goal is that *every tool and technique* a Linux system
78
-
administrator knows around how to build, inspect, mirror and manage
79
-
application containers also applies to bootable host systems.
80
-
81
-
There are a number of examples in e.g. [coreos/layering-examples](https://github.com/coreos/layering-examples).
82
-
83
-
First, build a derived container using any container build tooling.
84
-
85
-
#### Using `bootc install`
86
-
87
-
The `bootc install` command will write the current container to a disk, and set it up for booting.
88
-
In brief, the idea is that every container image shipping `bootc` also comes with a simple
89
-
installer that can set a system up to boot from it. Crucially, if you create a
90
-
*derivative* container image from a stock OS container image, it also automatically supports `bootc install`.
91
-
92
-
For more information, please see [docs/install.md](docs/install.md).
93
-
94
-
#### Switching from an existing ostree-based system
95
-
96
-
If you have [an operating system already using ostree](https://ostreedev.github.io/ostree/#operating-systems-and-distributions-using-ostree) then you can use `bootc switch`:
This will preserve existing state in `/etc` and `/var` - for example,
103
-
host SSH keys and home directories. There may be some issues with uid/gid
104
-
drift in this scenario however.
105
-
106
-
### Upgrading
107
-
108
-
Once a chosen container image is used as the boot source, further
109
-
invocations of `bootc upgrade` will look for newer versions - again
110
-
preserving state.
111
-
112
-
## Relationship with other projects
113
-
114
-
### Relationship with podman
115
-
116
-
It gets a bit confusing to talk about shipping bootable operating systems in container images.
117
-
Again, to be clear: we are reusing container images as:
118
-
119
-
- A build mechanism (including running *as* a standard OCI container image)
120
-
- A transport mechanism
121
-
122
-
But, actually when a bootc container is booted, podman (or docker, etc.) is not involved.
123
-
The storage used for the operating system content is distinct from `/var/lib/containers`.
124
-
`podman image prune --all` will not delete your operating system.
125
-
126
-
That said, a toplevel goal of bootc is alignment with the https://github.com/containers ecosystem,
127
-
which includes podman. But more specifically at a technical level, today bootc uses
128
-
[skopeo](https://github.com/containers/skopeo/) and hence indirectly [containers/image](https://github.com/containers/image)
129
-
as a way to fetch container images.
130
-
131
-
This means that bootc automatically also honors many of the knobs available in `/etc/containers` - specifically
132
-
things like [containers-registries.conf](https://github.com/containers/image/blob/main/docs/containers-registries.conf.5.md).
133
-
134
-
In other words, if you configure `podman` to pull images from your local mirror registry, then `bootc` will automatically honor that as well.
135
-
136
-
The simple way to say it is: A goal of `bootc` is to be the bootable-container analogue for `podman`, which runs application containers. Everywhere one might run `podman`, one could also consider using `bootc`.
137
-
138
-
### Relationship with Kubernetes
139
-
140
-
Just as `podman` does not depend on a Kubernetes API server, `bootc` will also not depend on one.
141
-
142
-
However, there are also plans for `bootc` to also understand Kubernetes API types. See [configmap/secret support](https://github.com/containers/bootc/issues/22) for example.
143
-
144
-
Perhaps in the future we may actually support some kind of `Pod` analogue for representing the host state. Or we may define a [CRD](https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/) which can be used inside and outside of Kubernetes.
145
-
146
-
### Relationship with rpm-ostree
147
-
148
-
Today rpm-ostree directly links to `ostree-rs-ext`, and hence
149
-
gains all the same container functionality. This will likely
150
-
continue. For example, with rpm-ostree (or, perhaps re-framed as
151
-
"dnf image"), it will continue to work to e.g. `dnf install`
152
-
(i.e. `rpm-ostree install`) on the *client side* system. However, `bootc upgrade` would
153
-
(should) then error out as it will not understand how to upgrade
154
-
the system.
155
-
156
-
rpm-ostree also has significant other features such as
157
-
`rpm-ostree kargs` etc.
158
-
159
-
Overall, rpm-ostree is used in several important projects
160
-
and will continue to be maintained for many years to come.
161
-
162
-
However, for use cases which want a "pure" image based model,
163
-
using `bootc` will be more appealing. bootc also does not
164
-
e.g. drag in dependencies on `libdnf` and the RPM stack.
165
-
166
-
bootc also has the benefit of starting as a pure Rust project;
167
-
and while it [doesn't have an IPC mechanism today](https://github.com/containers/bootc/issues/4), the surface
168
-
of such an API will be significantly smaller.
169
-
170
-
Further, bootc does aim to [include some of the functionality of zincati](https://github.com/containers/bootc/issues/5).
171
-
172
-
But all this said: *It will be supported to use both bootc and rpm-ostree together*; they are not exclusive.
173
-
For example, `bootc status` at least will still function even if packages are layered.
174
-
175
-
### Relationship with Fedora CoreOS (and Silverblue, etc.)
176
-
177
-
Per above, it is a toplevel goal to support a seamless, transactional update from existing OSTree based systems, which includes these Fedora derivatives.
178
-
179
-
For Fedora CoreOS specifically, see [this tracker issue](https://github.com/coreos/fedora-coreos-tracker/issues/1446).
180
-
181
-
See also [OstreeNativeContainerStable](https://fedoraproject.org/wiki/Changes/OstreeNativeContainerStable).
182
-
183
-
# More links
184
-
185
-
-https://coreos.github.io/rpm-ostree/container/
186
-
-https://github.com/coreos/layering-examples
18
+
# More information
187
19
20
+
See the [project documentation](https://containers.github.io/bootc/).
0 commit comments