Closed Aman4672 closed 3 years ago
The problem is that /var/run/docker/sock is owned by root (and group docker): $ ls -l /var/run/docker.sock srw-rw---- 1 root docker 0 apr 2 10:43 /var/run/docker.sock
And you are starting your container with PUID/PGID of 1000.
Normally outside docker, you can add to the uid=1000 the "docker" group as:
$ sudo usermod -a -G docker
Only this doesn't work in the container (unless you modify the Dockerfile)
Otherwise you can enable TCP/IP (see the Q&A of the main page) with using another container like: https://github.com/Tecnativa/docker-socket-proxy
I set the Puid and PGiD to the correct values for me, and it appears to be working. Thank you.
I got the component through hacs, added the config to the .yaml, and added docker to my user. I am using the same directory in a portainer container just fine
Configuration.yaml
monitor_docker:
Compose
version: "2.1" services: homeassistant: image: ghcr.io/linuxserver/homeassistant container_name: homeassistant network_mode: host environment: