From 3d663bf279a5a9e3099c7affaef14b06bcde21fa Mon Sep 17 00:00:00 2001 From: Jason Yip Date: Fri, 15 Mar 2024 20:29:07 -0700 Subject: [PATCH] fix userns option for rootless unix socket use case in install.md Given that the container runs as nobody user (with uid 65534 by default) and host uid, which is most likely not 65534, should map to container's uid 65534 Signed-off-by: Jason Yip --- install.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install.md b/install.md index 372209c5..78fe60b3 100644 --- a/install.md +++ b/install.md @@ -34,7 +34,7 @@ prometheus-podman-exporter is using go v1.17 or above. ```shell $ systemctl start --user podman.socket - $ podman run -e CONTAINER_HOST=unix:///run/podman/podman.sock -v $XDG_RUNTIME_DIR/podman/podman.sock:/run/podman/podman.sock -p 9882:9882 --userns=keep-id --security-opt label=disable quay.io/navidys/prometheus-podman-exporter + $ podman run -e CONTAINER_HOST=unix:///run/podman/podman.sock -v $XDG_RUNTIME_DIR/podman/podman.sock:/run/podman/podman.sock -p 9882:9882 --userns=keep-id:uid=65534 --security-opt label=disable quay.io/navidys/prometheus-podman-exporter ``` * Using unix socket (root):