Access to docker.sock in addon

Hi All,

I tried to search everywhere for this, but missing to find any info around how to expose the docker socker and other items to my custom Datadog v5 agent. I really like the datadog agent monitoring around docker and system performance and figured to write a plugin that exposes this info, perhaps including pulling of the logs to datadog.

My issue seems to be, knowing what to use on both a privilege side and a config.json side. I see in the addons repo there is a specific component for providing privileges to another addon, but cant see this in the hassio vagrant image to install it. as well as docs on what to configure.

I have tried to put the configs under maps and under devices (which fails).

Would really appreciate any help. Config below.

config.json

{
    "name": "Datadog v5",
    "version": "1",
    "slug": "datadog_v5",
    "description": "Enable datadog monitoring for your cluster with docker support",
    "startup": "system",
    "boot": "auto",
    "ports": {
      "8125/udp": 8125
    },
    "options": {
      "api_key": ""
    },
    "schema": {
      "api_key": "str"
    },
    "hassio_api": false,
    "homeassistant_api": false,
    "host_network": true,
    "hassio_role": "manager",
    "apparmor": false,
    "privileged": [
      "SYS_ADMIN",
      "SYS_RAWIO"
    ],
    "maps": [
      "/var/run/docker.sock:/var/run/docker.sock:ro",
      "/proc/:/host/proc/:ro",
      "/sys/fs/cgroup/:/host/sys/fs/cgroup:ro"
    ],    
    "docker_api": true,
    "host_ipc": true,
    "host_dbus": true,
    "host_pid": true,
    "full_access": true,
    "environment": {
      "LOG_FORMAT": "{LEVEL}: {MESSAGE}",
      "SUPERVISOR_VERSION": ">=0.77.0"
    }
}

I’ve got the datadog agent starting up nicely now in the container, just need help with figuring out how you allow a addon to use the docker socket. Effectively binding these 3 “volumes”

     "/var/run/docker.sock:/var/run/docker.sock:ro",
     "/proc/:/host/proc/:ro",
     "/sys/fs/cgroup/:/host/sys/fs/cgroup:ro"

when i run the addon manually on my machine, i feed this command in.

docker run -d \                   
  -v /var/run/docker.sock:/var/run/docker.sock:ro \
  -v /proc/:/host/proc/:ro \
  -v /sys/fs/cgroup/:/host/sys/fs/cgroup:ro \
  -e API_KEY=xxxx \
  hassio-addon/datadog-v5:0.0.11

Hello, have you ever found a solution ?
I am trying to make systemd works in a container in hassio but cant find a way…

Has anyone found a way to make systemd work in a home assistant addon?