enesbcs / rpieasy

Easy MultiSensor device based on Raspberry PI
GNU General Public License v3.0
159 stars 33 forks source link

[Feature] Download link compatibility to ESPEasy #228

Closed clumsy-stefan closed 10 months ago

clumsy-stefan commented 3 years ago

In ESPEasy it's possible to download the stored files (eg. config.dat, rules<n>.txt) via direct links eg. http://node.domain/config.dat.

For backup reasons I did some scripts that go through all nodes and download these config and rules data.

It would be nice if also RPIEasy could be (easily) included in these backups and the files downloaded.

enesbcs commented 3 years ago

Config files already can be saved at once as a zip file from: http://IPADDRESS/download?type=settings But i have to admit, that rules.txt is not yet included in it.

clumsy-stefan commented 3 years ago

I guess my vote is to have the same URL as for ESPEasy to be able to treat it the same in scripts. Currently I have to differentiate if I'm talking to an RPIEasy node or to a ESPEasy node...

Currently I have a script that loops over my 30ish ESPEasy nodes doing a wget of all files. Can't use that for RPIEasy like this.

enesbcs commented 3 years ago

Currently I have to differentiate if I'm talking to an RPIEasy node or to a ESPEasy node...

Yes, i think differentiate is the best approach as RPIEasy is not ESPEasy, just similar.

From my point of view, there are no 1:1 association between "config.dat" binary file and RPIEasy json text files...

What URL associations do you suggest for advsettings.json, controllers.json, netdev.json, notifiers.json, tasks.json, controllers.json, netman.json and settings.json RPIEasy files to achieve ESPEasy compatibility?

clumsy-stefan commented 3 years ago

In ESPEasy its always http://node.name.domain/<filename> if the filename exists it sends it. I agree that this is not completely collision free, but it works quite smoothly. If the file is not found obviously it doesn't send it and tests if it's actually a command.

enesbcs commented 10 months ago

added config.dat and rules1.txt download option at commit https://github.com/enesbcs/rpieasy/commit/dc8ccd36c5431463f076c3e2ec65c08e47a79637

clumsy-stefan commented 10 months ago

thanks!