Skip to content

djrarky/telegraf-python3

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Telegraf container containing prerequisites for the following scripts

Configure

Run in Docker

docker run -d --name=telegraf \
  --network host \
  --restart=always \
  -v location/telegraf.conf:/etc/telegraf/telegraf.conf:ro \
  ghcr.io/djrarky/telegraf-python3

Docker Compose Setup

services:
  telegraf:
    image: ghcr.io/djrarky/telegraf-python3
    container_name: telegraf
    restart: always
    network_mode: "host"
    volumes:
      - location/telegraf.conf:/etc/telegraf/telegraf.conf:ro

Telegraf Setup

[[inputs.exec]]
  ## Commands array
  commands = [
    "python3 /opt/scripts/tplink-hs110-telegraf/telegraf-tplink-hs110.py 'plugName1' 'IPAddress1' 'plugName2' 'IPAddress2'",
    "python3 /opt/scripts/huawei-lte-telegraf/telegraf-huawei-lte.py 'http://username:password@IP Address/'"
    "python3 /opt/scripts/huawei-hg612-telegraf/dsl-stats-to-influxdb-3.py 'IPAddress' 'username' 'password'"
  ]

  ## measurement name suffix (for separating different commands)
  name_suffix = "_mycollector"

  ## Data format to consume.
  data_format = "influx"

About

telegraf including dependencies for my inputs.exec scripts

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages