Giter Club home page Giter Club logo

prom-hue-sensors's Introduction

Prometheus exporter for Hue Sensors

This program allows you to gather generic metrics on all your Philips Hue sensors with Prometheus.

Installation

Installation of prom-hue-sensors can be done by running this command:

go install github.com/skoef/prom-hue-sensors@latest

Alternatively, a Docker container is available as well:

docker run rschoof/prom-hue-sensors

Registering a new user

To be able to gather metrics on the sensors, a user should be registered with Hue. This is quite simple actually. Run the following command:

prom-hue-sensors -register

and press the big button on the front of the Hue bridge within one minute. If it takes more than one minute to walk over to your Hue bridge and press the button, increase the timeout with -register-timeout 5m for instance.

The registration command can directly store the user key in a file by passing -user-key-path /path/to/file to the register command

Running

When a user key was registered, there are several ways you can invoke prom-hue-sensors:

  • Pass the user key from the commandline like this:
prom-hue-sensors -user s3cr3tus3rk3y
  • Pass the user key as an environment variable like this:
HUE_USER=s3cr3tus3rk3y prom-hue-sensors
  • Pass the user key stored in a file like this:
prom-hue-sensors -user-key-path /path/to/file

Kubernetes

The container is built for ARM64 (as well as AMD64 and ARM7) so suitable for running on kubernetes on a Raspberry Pi for instance. In the manifests/ directory are 2 examples of deployments: deployment-key.yaml and deployment-register.yaml for running the container with a preregistered key or registering a key on the spot respectively.

prom-hue-sensors's People

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.