Hi,
So, I'm new to this and I'm probably doing it wrong.
I used your docker-compose file, added the volume '- "/etc/telegraf/telegraf.conf:/etc/telegraf/telegraf.conf:ro"'.
For the life of me, I cannot figure out why telegraf doesn't read my .conf files. Telegraf appears to be polling the localhost as intended, as I can see measurements in influx. I've added the .conf files to /etc/telegraf/telegraf.d directory, just as I did on my regular build machine.
I can initiate a poll manually from the container itself, specifying the .conf file and it will do the snmp walk, as expected.
I also cannot edit the telegraf.conf file in the container itself. When I look at the file permissions, it shows:
-rw-r--r-- 1 989 983 334096 Oct 12 09:30 telegraf.conf
The container does run successfully:
today at 5:46:58 AM Container started
today at 5:45:34 AM 2021-10-12T09:45:34Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:"localhost.localdomain", Flush Interval:10s
today at 5:46:58 AM 2021-10-12T09:46:58Z I! Starting Telegraf 1.20.2
today at 5:46:58 AM 2021-10-12T09:46:58Z I! Using config file: /etc/telegraf/telegraf.conf
today at 5:46:58 AM 2021-10-12T09:46:58Z I! Loaded inputs: cpu disk diskio kernel mem processes swap system
today at 5:46:58 AM 2021-10-12T09:46:58Z I! Loaded aggregators:
today at 5:46:58 AM 2021-10-12T09:46:58Z I! Loaded processors:
today at 5:46:58 AM 2021-10-12T09:46:58Z I! Loaded outputs: influxdb
today at 5:46:58 AM 2021-10-12T09:46:58Z I! Tags enabled: host=localhost.localdomain
today at 5:46:58 AM 2021-10-12T09:46:58Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:"localhost.localdomain", Flush Interval:10s
Any ideas?
Thanks for the help in advance.