Skip to content

Commit 9201730

Browse files
committed
docs: document full node requirements (postgres, dm targets, kvm, cgroup v2, suidhelper)
1 parent d5bffcc commit 9201730

1 file changed

Lines changed: 52 additions & 7 deletions

File tree

docs/cookbook/intro.md

Lines changed: 52 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,58 @@ The absolute best way to get started with `Hyper` is to play with it.
1919

2020
### Requirements
2121

22-
Hyper requires the following software be installed on each node running it:
23-
24-
- [`skopeo`](https://github.com/containers/skopeo)
25-
- [`e2fsprogs`](https://github.com/tytso/e2fsprogs)
26-
27-
Hyper has more runtime dependencies, but they are automatically redistributed
28-
by Hyper.
22+
#### External services
23+
24+
Hyper needs a **PostgreSQL** server reachable from every node — it is the image
25+
database and the only stateful external dependency.
26+
27+
#### System binaries
28+
29+
The following must be on each node's `PATH` (the bracketed override is the
30+
`config :hyper` key you can set if the binary lives elsewhere):
31+
32+
- [`skopeo`](https://github.com/containers/skopeo) — pulls OCI images
33+
(`skopeo_path`)
34+
- [`e2fsprogs`](https://github.com/tytso/e2fsprogs) — provides `mke2fs`, which
35+
builds the ext4 rootfs (`mke2fs_path`)
36+
- `losetup`, `blockdev` (from **util-linux**) — loop-device setup
37+
(`losetup_path`, `blockdev_path`)
38+
- `dmsetup` (from **lvm2** / device-mapper) — dm-snapshot and thin-pool
39+
layering (`dmsetup_path`). Frequently *not* installed by default — check
40+
this one first.
41+
- `du`, `getent` (from **coreutils** and **glibc**) — rootfs sizing and user
42+
resolution. Present on essentially every distro.
43+
44+
#### Kernel features
45+
46+
The host kernel must provide:
47+
48+
- **KVM**`/dev/kvm` must exist and be accessible to the per-VM users (see
49+
the `uid_gid_range` configuration).
50+
- **cgroup v2** — the unified hierarchy mounted at `/sys/fs/cgroup`. v1-only
51+
hosts are not supported.
52+
- **device-mapper targets** `snapshot`, `thin`, and `thin-pool` — load the
53+
`dm_snapshot` and `dm_thin_pool` modules (`modprobe dm_snapshot
54+
dm_thin_pool`). Hyper refuses to start its device helper without them.
55+
- **loop devices** — the `loop` module, used to attach layer images as block
56+
devices.
57+
58+
#### Privileged setup
59+
60+
- The **setuid-root device helper** (`hyper-suidhelper`) must be installed.
61+
Run `mix suidhelper.install`, which builds, stamps, and places it
62+
setuid-root on `PATH`. Every privileged operation (losetup, dmsetup, mknod,
63+
chroot jails) routes through it; the BEAM itself runs unprivileged.
64+
- A **parent cgroup** named by `cgroup_parent` (default `hyper`) must exist
65+
under `/sys/fs/cgroup`; Hyper creates each VM's cgroup beneath it.
66+
- The host UID/GID range given by `uid_gid_range` must be free for Hyper to
67+
allocate per-VM users from.
68+
69+
#### Auto-redistributed
70+
71+
The remaining runtime dependencies — `firecracker`, `jailer`, `umoci`, and the
72+
guest `vmlinux` kernels — are downloaded, checksum-verified, and managed by
73+
Hyper itself; you do not install them.
2974

3075
### Installation
3176

0 commit comments

Comments
 (0)