version: "3.9" services: portainer-agent: image: portainer/agent:2.20.3-alpine container_name: portainer-agent privileged: true expose: - "9001" ports: - "9001:9001" volumes: - /var/run/docker.sock:/var/run/docker.sock restart: always