mirror of
https://github.com/unpoller/unpoller.git
synced 2026-04-05 00:44:09 -04:00
this is just a start, nothing works yet
This commit is contained in:
@@ -89,10 +89,10 @@ is provided so the application can be easily adapted to any environment.
|
||||
mode default: "influx"
|
||||
* Value: influx
|
||||
This default mode runs this application as a daemon. It will poll
|
||||
the controller at the configured interval. Providing an invalid value
|
||||
will run in this default mode.
|
||||
the controller at the configured interval and report measurements to
|
||||
InfluxDB. Providing an invalid value will run in this default mode.
|
||||
|
||||
* Value: influxlambda - (the only other available option right now)
|
||||
* Value: influxlambda
|
||||
Setting this value will invoke a run-once mode where the application
|
||||
immediately polls the controller and reports the metrics to InfluxDB.
|
||||
Then it exits. This mode is useful in an AWS Lambda or a crontab where
|
||||
@@ -101,6 +101,16 @@ is provided so the application can be easily adapted to any environment.
|
||||
This mode can also be combined with a "test database" in InfluxDB to
|
||||
give yourself a "test config file" you may run ad-hoc to test changes.
|
||||
|
||||
* Value: prometheus
|
||||
In this mode the application opens an http interface and exports the
|
||||
measurements at /metrics for collection by prometheus. Enabling this
|
||||
mode disables InfluxDB usage entirely.
|
||||
|
||||
http_listen default: 0.0.0.0:61317
|
||||
This option controls the IP and port the http listener uses when the
|
||||
mode is set to prometheus. This setting has no effect when other modes
|
||||
are in use.
|
||||
|
||||
influx_url default: http://127.0.0.1:8086
|
||||
This is the URL where the Influx web server is available.
|
||||
|
||||
|
||||
@@ -24,13 +24,21 @@ quiet = false
|
||||
# an invalid mode will also result in "influx". In this default mode the application
|
||||
# runs as a daemon and polls the controller at the configured interval.
|
||||
#
|
||||
# There is only one other option at this time: "influxlambda"
|
||||
# There are two other options at this time: "influxlambda" and "prometheus"
|
||||
#
|
||||
# Lambda mode makes the application exit after collecting and reporting metrics
|
||||
# to InfluxDB one time. This mode requires an external process like an AWS Lambda
|
||||
# or a simple crontab to keep the timings accurate on UniFi Poller run intervals.
|
||||
#
|
||||
# Prometheus mode opens an HTTP server on port 61317 and exports the metrics at
|
||||
# /metrics for polling collection by a prometheus server. This disables influxdb.
|
||||
mode = "influx"
|
||||
|
||||
|
||||
# This controls on which ip and port /metrics is exported when mode is "prometheus".
|
||||
# This has no effect in other modes. Must contain a colon and port.
|
||||
http_listen = "0.0.0.0:61317"
|
||||
|
||||
# InfluxDB does not require auth by default, so the user/password are probably unimportant.
|
||||
influx_url = "http://127.0.0.1:8086"
|
||||
influx_user = "unifi"
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"debug": false,
|
||||
"quiet": false,
|
||||
"mode": "influx",
|
||||
"http_listen": "0.0.0.0:61317",
|
||||
"influx_url": "http://127.0.0.1:8086",
|
||||
"influx_user": "unifi",
|
||||
"influx_pass": "unifi",
|
||||
|
||||
@@ -40,14 +40,23 @@
|
||||
# an invalid mode will also result in "influx". In this default mode the application
|
||||
# runs as a daemon and polls the controller at the configured interval.
|
||||
#
|
||||
# There is only one other option at this time: "influxlambda"
|
||||
# There are two other options at this time: "influxlambda" and "prometheus"
|
||||
#
|
||||
# Lambda mode makes the application exit after collecting and reporting metrics
|
||||
# to InfluxDB one time. This mode requires an external process like an AWS Lambda
|
||||
# or a simple crontab to keep the timings accurate on UniFi Poller run intervals.
|
||||
#
|
||||
# Prometheus mode opens an HTTP server on port 61317 and exports the metrics at
|
||||
# /metrics for polling collection by a prometheus server. This disables influxdb.
|
||||
-->
|
||||
<mode>influx</mode>
|
||||
|
||||
<!--
|
||||
# This controls on which ip and port /metrics is exported when mode is "prometheus".
|
||||
# This has no effect in other modes. Must contain a colon and port.
|
||||
-->
|
||||
<http_listen>0.0.0.0:61317</http_listen>
|
||||
|
||||
<!--
|
||||
# InfluxDB does not require auth by default, so the user/password are probably unimportant.
|
||||
-->
|
||||
|
||||
@@ -25,13 +25,20 @@ quiet: false
|
||||
# an invalid mode will also result in "influx". In this default mode the application
|
||||
# runs as a daemon and polls the controller at the configured interval.
|
||||
#
|
||||
# There is only one other option at this time: "influxlambda"
|
||||
# There are two other options at this time: "influxlambda" and "prometheus"
|
||||
#
|
||||
# Lambda mode makes the application exit after collecting and reporting metrics
|
||||
# to InfluxDB one time. This mode requires an external process like an AWS Lambda
|
||||
# or a simple crontab to keep the timings accurate on UniFi Poller run intervals.
|
||||
#
|
||||
# Prometheus mode opens an HTTP server on port 61317 and exports the metrics at
|
||||
# /metrics for polling collection by a prometheus server. This disables influxdb.
|
||||
mode: "influx"
|
||||
|
||||
# This controls on which ip and port /metrics is exported when mode is "prometheus".
|
||||
# This has no effect in other modes. Must contain a colon and port.
|
||||
http_listen: "0.0.0.0:61317"
|
||||
|
||||
# InfluxDB does not require auth by default, so the user/password are probably unimportant.
|
||||
influx_url: "http://127.0.0.1:8086"
|
||||
influx_user: "unifi"
|
||||
|
||||
Reference in New Issue
Block a user