Skip to content

Commit e0f4c05

Browse files
committed
updates
1 parent 4bc7d5a commit e0f4c05

File tree

2 files changed

+25
-5
lines changed

2 files changed

+25
-5
lines changed

README.md

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -87,16 +87,23 @@ When running, use `-t` to enable the logging to `docker logs`
8787
A container should be started using these commands, among others. See
8888
also the section on environment variables, below.
8989

90-
## Container Invocation, sysvinit containers (jessie/stretch)
91-
92-
docker run -td --stop-signal=SIGPWR --name=name jgoerzen/debian-base-whatever
90+
## Container Invocation, systemd containers (buster/bullseye/sis)
9391

94-
## Container Invocation, systemd containers (buster/bullseye/sid)
92+
Here's how you invoke for systemd (buster/bullseye) on a system running an older systemd on the host, with cgroups v1:
9593

9694
docker run -td --stop-signal=SIGRTMIN+3 \
9795
--tmpfs /run:size=100M --tmpfs /run/lock:size=100M \
9896
-v /sys/fs/cgroup:/sys/fs/cgroup:ro \
9997
--name=name jgoerzen/debian-base-whatever
98+
99+
For a host running bullseye, or a newer cgroups and systemd, you have to use this:
100+
101+
docker run -td --stop-signal=SIGRTMIN+3 \
102+
--tmpfs /run:size=100M --tmpfs /run/lock:size=100M \
103+
-v /sys/fs/cgroup:/sys/fs/cgroup:rw --cgroupns=host \
104+
--name=name jgoerzen/debian-base-whatever
105+
106+
Note that the buster image has not been tested under these situations, and since bullseye is now stable, it is the recommended image for all modern deployments.
100107

101108
The `/run` and `/run/lock` tmpfs are required by systemd. The 100M
102109
sets a maximum size, not a default allocation, and serves to limit the
@@ -106,6 +113,19 @@ down from a default limit of 16G.
106113
Note that these images, contrary to many others out there, do NOT
107114
require `--privileged`.
108115

116+
For more information about the systemd/cgroups situation, consult these links
117+
118+
- https://github.com/systemd/systemd/issues/19245
119+
- https://github.com/containers/podman/issues/5153
120+
- https://github.com/moby/moby/issues/42275
121+
- https://serverfault.com/questions/1053187/systemd-fails-to-run-in-a-docker-container-when-using-cgroupv2-cgroupns-priva/1054414#1054414
122+
- http://docs.podman.io/en/latest/markdown/podman-run.1.html#cgroupns-mode
123+
-
124+
125+
## Container Invocation, sysvinit containers (jessie/stretch)
126+
127+
docker run -td --stop-signal=SIGPWR --name=name jgoerzen/debian-base-whatever
128+
109129
# Environment Variables
110130

111131
This environment variable is available for your use:

0 commit comments

Comments
 (0)