Telegraf could not find file


Go to solution Solved by rcjk,

Recommended Posts

Hello,

 

I am using the atribe's Telgraf docker and am struggling with making connections to files. I have only had success for HTTP scrapping so far. 

 

I plan to use my weather api with the HTTP plugin to get daily weather from my station. I made a quick python script to download the last 2 years historical data which are currently saved as .JSONs. My next steps are I want to use starlark to change json to inline format but I am unable to find any files getting this error:

 

Error in plugin: could not find file: weather/20200830.json

 

What I have done so far is put all my JSONs in this folder:

/mnt/user/Python/weather_data/

 

I then added the path as below to telegraf


image.thumb.png.89b2facc06a2681496b2b53d350285f6.png

 

Then on my telgraf.conf, I have typed:

[[inputs.file]]

     files = ["/weather/20200830.json"]

     data_format = "value"

     data_type = "string"

 

Any guidance is appreciated, I am not 100% confident if I understand the file structure or how dockers "see" folders. From reading online it seems the dockers do not see unraid and you have to point it to the folder location which is what I attempted above. 

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.