services: prometheus: image: prom/prometheus:latest container_name: prometheus restart: unless-stopped user: "${PUID:-1000}:${PGID:-1000}" command: - --config.file=/etc/prometheus/prometheus.yml - --storage.tsdb.path=/prometheus - --storage.tsdb.retention.time=${RETENTION:-30d} - --web.enable-lifecycle ports: - "${HTTP_PORT:-9090}:9090" volumes: - ./prometheus.yml:/etc/prometheus/prometheus.yml:ro - ${DATA_PATH:-/srv/prometheus}:/prometheus node-exporter: image: prom/node-exporter:latest container_name: node-exporter restart: unless-stopped pid: host command: - --path.rootfs=/host volumes: - /:/host:ro,rslave cadvisor: image: gcr.io/cadvisor/cadvisor:latest container_name: cadvisor restart: unless-stopped privileged: true devices: - /dev/kmsg volumes: - /:/rootfs:ro - /var/run:/var/run:ro - /sys:/sys:ro - /var/lib/docker/:/var/lib/docker:ro