version: "3.9"

networks:
  hxki-internal:
    external: true

services:
  node-exporter:
    image: prom/node-exporter:v1.8.1
    container_name: hxki-node-exporter
    restart: unless-stopped
    command:
      - --path.rootfs=/host
      - --collector.systemd
      - --collector.processes
      - --collector.filesystem
    volumes:
      - "/:/host:ro,rslave"
    ports:
      - "9100:9100"
    networks:
      - hxki-internal

  cadvisor:
    image: gcr.io/cadvisor/cadvisor:latest
    container_name: hxki-cadvisor
    restart: unless-stopped
    privileged: true
    volumes:
      - "/:/rootfs:ro"
      - "/var/run:/var/run:ro"
      - "/sys:/sys:ro"
      - "/var/lib/docker:/var/lib/docker:ro"
      - "/dev/disk:/dev/disk:ro"
    ports:
      - "8080:8080"
    networks:
      - hxki-internal
