switch to rootless podman
This commit is contained in:
parent
c8324f0922
commit
c20ce4fd6c
1 changed files with 9 additions and 7 deletions
|
|
@ -1,19 +1,21 @@
|
||||||
[Unit]
|
[Unit]
|
||||||
Description=Docker-in-Podman
|
Description=Rootless Podman-in-Podman
|
||||||
|
|
||||||
[Container]
|
[Container]
|
||||||
Image=docker.io/library/docker:dind
|
Image=quay.io/podman/stable
|
||||||
ContainerName=dind
|
ContainerName=dind
|
||||||
AutoUpdate=registry
|
AutoUpdate=registry
|
||||||
Environment=DOCKER_HOST=unix:///var/run/docker.sock
|
|
||||||
SecurityLabelDisable=true
|
SecurityLabelDisable=true
|
||||||
PodmanArgs=--privileged --cgroupns=host
|
Unmask=ALL
|
||||||
HealthCmd=docker info || exit 1
|
AddDevice=/dev/fuse
|
||||||
|
HealthCmd=podman info || exit 1
|
||||||
HealthInterval=5s
|
HealthInterval=5s
|
||||||
HealthTimeout=3s
|
HealthTimeout=3s
|
||||||
HealthRetries=5
|
HealthRetries=5
|
||||||
Volume=dind.volume:/var/lib/docker:Z
|
User=podman
|
||||||
Volume=/var/run/dind:/var/run:z
|
Volume=dind.volume:/home/podman/.local/share/containers:Z
|
||||||
|
Volume=/var/run/dind:/var/run/1000:z
|
||||||
|
Exec=sh -c "podman system service --time=0 unix:///var/run/1000/docker.sock & PID=$!; while [ ! -S /var/run/1000/docker.sock ]; do sleep 0.1; kill -0 $PID 2>/dev/null || exit 1; done && chmod 0666 /var/run/1000/docker.sock && wait $PID"
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Restart=always
|
Restart=always
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue