Use nsenter with pid:host to run zpool in host mount namespace

This commit is contained in:
2026-03-07 04:04:15 +00:00
parent 034219c75e
commit 10de5563b2
2 changed files with 10 additions and 11 deletions

View File

@@ -5,16 +5,13 @@ services:
container_name: jbod-monitor
restart: unless-stopped
privileged: true
pid: host
network_mode: host
volumes:
- /dev:/dev
- /sys:/sys:ro
- /run/udev:/run/udev:ro
- /usr/sbin/zpool:/host/zpool:ro
- /usr/sbin/zfs:/host/zfs:ro
- /lib/x86_64-linux-gnu:/host/lib:ro
environment:
- TZ=America/Denver
- UVICORN_LOG_LEVEL=info
- ZPOOL_BIN=/host/zpool
- ZFS_HOST_LIB=/host/lib
- ZFS_USE_NSENTER=true