Creating a local file copy
Posted: Fri 17 Mar 2023 11:31 pm
This is a question about Mark's "Announcement" notes on 8th March re Build 3231.
Firstly I should say this is another excellent job, as always. I actually picked up the subsequent patch release (Build 3235) today and this was my first update since 3149 in October 2021. Given there were some significant changes since then I was a bit worried, but everything worked fine as usual (albeit I am still using SFTP uploads of complete JSON files to my remote webserver for now anyway - PHP Upload might come later!).
My question is about the mention in the above note about Extra (web) Files, and Mark's 2nd suggestion to "Add an additional file entry (before the uploads) to create a local copy for subsequent uploads to use." I am wondering what medium this refers to (i.e. where should I add such an entry)? If this is referring to the Extra Web Files section in Settings, it does not have a Create Copy column.
I should explain that I previously used Extra Files to process a small json template at the Realtime interval to provide a few data items for a home weather display panel running locally off the raspberry pi, including things like cpu temp, system uptime, packet counts and errors etc. Don't laugh, I'm sure there is a better way of doing this, but my javascript skills are not great, and I couldn't figure out how to bend any of the local interface scripts to pick up my items! So I simply ticked the "Process" column but not "Upload" so the .jsontmp file it produced could be parsed by a small script I created by copying part of the setpagedata script. Now that local tmp copies are no longer produced, this has stopped working. I can see that the various standard interval files can be configured to create copies, but not the extra ones. Or is there a way to set a local directory for the file upload destination somehow?
Firstly I should say this is another excellent job, as always. I actually picked up the subsequent patch release (Build 3235) today and this was my first update since 3149 in October 2021. Given there were some significant changes since then I was a bit worried, but everything worked fine as usual (albeit I am still using SFTP uploads of complete JSON files to my remote webserver for now anyway - PHP Upload might come later!).
My question is about the mention in the above note about Extra (web) Files, and Mark's 2nd suggestion to "Add an additional file entry (before the uploads) to create a local copy for subsequent uploads to use." I am wondering what medium this refers to (i.e. where should I add such an entry)? If this is referring to the Extra Web Files section in Settings, it does not have a Create Copy column.
I should explain that I previously used Extra Files to process a small json template at the Realtime interval to provide a few data items for a home weather display panel running locally off the raspberry pi, including things like cpu temp, system uptime, packet counts and errors etc. Don't laugh, I'm sure there is a better way of doing this, but my javascript skills are not great, and I couldn't figure out how to bend any of the local interface scripts to pick up my items! So I simply ticked the "Process" column but not "Upload" so the .jsontmp file it produced could be parsed by a small script I created by copying part of the setpagedata script. Now that local tmp copies are no longer produced, this has stopped working. I can see that the various standard interval files can be configured to create copies, but not the extra ones. Or is there a way to set a local directory for the file upload destination somehow?