summaryrefslogtreecommitdiff
path: root/meta-unit-virtualization
diff options
context:
space:
mode:
authorunitexe <unitexe70@gmail.com>2026-09-17 23:25:58 -0500
committerunitexe <unitexe70@gmail.com>2026-09-17 23:25:58 -0500
commitb1f6a1e650ef2872de65a77f3f557d9dc7f9284a (patch)
tree1249761f874deb222f3cb88f584db7c2aa8bb82b /meta-unit-virtualization
parent9e5f459d57bb703b6cd58970fa34cbc5e7bd850b (diff)
Fix rootless podman prometheus exporter
- Exporter runs as nobody, the rootless podman socket belongs to svc and only svc can use it - The podman library inside the exporter decides its rootless by looking for per-user config in $HOME/.config - $HOME inside the image is /home and /home/.config doesn't exist and the library treats a missing config directory as fatal error - The config directory being mounted has to belong to the user reading it Ironically, the directory stays empty and nothing ever reads from it. The mount gets the exporter past a startup check that assumes its running on a normal host, not in a minimal busybox container.
Diffstat (limited to 'meta-unit-virtualization')
-rw-r--r--meta-unit-virtualization/recipes-containers/prometheus-podman-exporter-rootless/files/prometheus-podman-exporter.container1
1 files changed, 1 insertions, 0 deletions
diff --git a/meta-unit-virtualization/recipes-containers/prometheus-podman-exporter-rootless/files/prometheus-podman-exporter.container b/meta-unit-virtualization/recipes-containers/prometheus-podman-exporter-rootless/files/prometheus-podman-exporter.container
index 0cdfb0b..bc94095 100644
--- a/meta-unit-virtualization/recipes-containers/prometheus-podman-exporter-rootless/files/prometheus-podman-exporter.container
+++ b/meta-unit-virtualization/recipes-containers/prometheus-podman-exporter-rootless/files/prometheus-podman-exporter.container
@@ -11,6 +11,7 @@ Volume=%t/podman/podman.sock:/run/podman/podman.sock:ro
Environment=CONTAINER_HOST=unix:///run/podman/podman.sock
PodmanArgs=--userns=keep-id:uid=65534
Exec=--collector.enable-all
+Mount=type=tmpfs,destination=/home/.config,tmpfs-mode=0700,chown
[Service]
Restart=on-failure