Skip to content

Instantly share code, notes, and snippets.

@jonchen727
Created June 7, 2022 15:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jonchen727/237eb392566e0c4d5b3ac8f3b89cb6a9 to your computer and use it in GitHub Desktop.
Save jonchen727/237eb392566e0c4d5b3ac8f3b89cb6a9 to your computer and use it in GitHub Desktop.
Telegraf Configuration to Pull Enphase Module Data
# Global tags can be specified here in key="value" format.
[global_tags]
# Configuration for telegraf agent
[agent]
interval = "60s"
round_interval = true
metric_batch_size = 1000
metric_buffer_limit = 10000
collection_jitter = "0s"
flush_interval = "30s"
flush_jitter = "10s"
precision = ""
hostname = ""
omit_hostname = false
###############################################################################
# OUTPUT PLUGINS #
###############################################################################
# Configuration for sending metrics to InfluxDB
[[outputs.influxdb]]
urls = ["http://influxdb.default.svc.cluster.local:8086"]
database = "Envoy"
###############################################################################
# INPUT PLUGINS #
###############################################################################
[[inputs.exec]]
# Replace pass with last 6 digits of envoy serial number.
commands = [
"curl -m 300 --digest -u 'envoy:[pass]' http://[Envoy_IP]/api/v1/production/inverters"
]
timeout = "60s"
data_format = "json"
json_strict = true
tag_keys = ["serialNumber"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment