rcooler/ugos-bridge

By rcooler

Updated 3 months ago

Image
0

745

rcooler/ugos-bridge repository overview

ugos-bridge overview

Lightweight metrics bridge for UGOS / UGREEN NAS hosts, Docker Compose stacks, and QEMU/libvirt virtual machines. It collects Docker, VM, host, storage, network, GPU, and hardware health telemetry and exports it to Prometheus and MQTT/Home Assistant discovery.

Prometheus listens on :9877 by default. MQTT/Home Assistant export is optional and can be enabled with environment variables.

GitHub: https://github.com/RCooLeR/UgosBridge

Docker Compose

services:
  ugos-bridge:
    image: rcooler/ugos-bridge:latest
    container_name: ugos-bridge
    restart: unless-stopped
    ports:
      - "9877:9877"
    environment:
      UGOS_BRIDGE_LISTEN_ADDRESS: ":9877"
      UGOS_BRIDGE_DOCKER_HOST: "unix:///var/run/docker.sock"
      UGOS_BRIDGE_SCRAPE_INTERVAL: "15s"
      UGOS_BRIDGE_HOST_METRICS_ENABLED: "true"
      UGOS_BRIDGE_HOST_PROCFS: "/host/proc"
      UGOS_BRIDGE_HOST_SYSFS: "/host/sys"
      UGOS_BRIDGE_HOST_NAME: "ugreen-nas"
      UGOS_BRIDGE_HOST_HOSTNAME_PATH: "/rootfs/etc/hostname"
      UGOS_BRIDGE_HOST_FILESYSTEMS: "/:/rootfs,/volume1:/volume1,/volume2:/volume2"
      UGOS_BRIDGE_HOST_VMS_ENABLED: "true"
      UGOS_BRIDGE_HOST_VIRSH_URI: "qemu:///system"
      UGOS_BRIDGE_MQTT_ENABLED: "false"
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock:ro
      - /proc:/host/proc:ro
      - /sys:/host/sys:ro
      - /:/rootfs:ro
      - /volume1:/volume1:ro
      - /volume2:/volume2:ro
      - /var/run/libvirt:/var/run/libvirt:ro

Enable MQTT/Home Assistant discovery by setting:

      UGOS_BRIDGE_MQTT_ENABLED: "true"
      UGOS_BRIDGE_MQTT_BROKER: "tcp://homeassistant.local:1883"
      UGOS_BRIDGE_MQTT_USER: "ha"
      UGOS_BRIDGE_MQTT_PASS: "change_me"
      UGOS_BRIDGE_MQTT_TOPIC_PREFIX: "ugos_bridge"
      UGOS_BRIDGE_MQTT_DISCOVERY_PREFIX: "homeassistant"
      UGOS_BRIDGE_MQTT_RETAIN: "true"
      UGOS_BRIDGE_MQTT_EXPIRE_AFTER: "360"

UgosBridge is an unofficial compatibility project and is not affiliated with, endorsed by, or sponsored by UGREEN.

Tag summary

Content type

Image

Digest

sha256:e5c6254c8

Size

65.4 MB

Last updated

3 months ago

docker pull rcooler/ugos-bridge