Sign inSign up

moikot/smartthings-metrics

By moikot

Updated over 5 years ago

🔥Provides SmartThings metrics to Prometheus

Image
0

10K+

moikot/smartthings-metrics repository overview

SmartThings metrics

ci docker
A micro-service that provides SmartThings metrics to Prometheus.

Run

For this service to have access to SmartThings API you need to provide it with a personal access token (PAT). To generate a PAT do the following:

  1. Open SmartThings Personal access tokens page.
  2. Click "GENERATE NEW TOKEN" button.
  3. Give it a name and enable "Devices/List all devices" and "Devices/See all devices" scopes.
  4. Click "GENERATE TOKEN" button.
Run as a standalone app

Prerequisites:

$ go get github.com/moikot/smartthings-metrics
$ smartthings-metrics -token [Smarthings-API-token]
Run as a Docker container

Prerequisites:

$ docker run -d --rm -p 9153:9153 moikot/smartthings-metrics -token [Smarthings-API-token]
$ curl localhost:9153/metrics
Deploy to a Kubernetes cluster

Prerequisites:

SmartThing metrics service is installed to Kubernetes via its Helm chart.

$ helm repo add moikot https://moikot.github.io/helm-charts
$ helm install smartthings-metrics moikot/smartthings-metrics --create-namespace --names
pace smartthings --set token=[Smarthings-API-token] 

Tag summary

Content type

Image

Digest

Size

10 MB

Last updated

over 5 years ago

docker pull moikot/smartthings-metrics