Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restore backup to a newly flashed device #1931

Open
cconde opened this issue Oct 3, 2019 · 5 comments
Open

Restore backup to a newly flashed device #1931

cconde opened this issue Oct 3, 2019 · 5 comments
Labels
enhancement New feature or request web interface

Comments

@cconde
Copy link
Contributor

cconde commented Oct 3, 2019

Is your feature request related to a problem? Please describe.
After messing with firmware I tend to have to restore a backup.
In order to restore a backup I have first to reset the default password and then go to "Admin" to restore the backup.

Describe the solution you'd like
It would be superb to have a "Set password & restore config" button at that very first page.

Describe alternatives you've considered
I don't know if it's possible, it would be totally awesome if the restore would also restore the original password.

Additional context
I keep in mind this may only be useful to few people.

Thanks for this great work!

@cconde cconde added the enhancement New feature or request label Oct 3, 2019
@mcspr
Copy link
Collaborator

mcspr commented Oct 11, 2019

On a sort-of related note, the starting page could use WiFi setup as well.

You can also skip WebUI completely, see:
https://github.com/xoseperez/espurna/wiki/Configuration#direct-http-settings-api
This will overwrite configuration using the current password

@Tofandel
Copy link

Tofandel commented Oct 17, 2019

Was thinking about improving the first step as well for the UI, it's a tad annoying

Isn't the password stored in the config backup?

Cause then you can just have a first step like:
Restore backup or set Password and Wifi

And then connect to the device via local network instead of the usual
Change password => reconnect => setWifi => reconnect again

@Tofandel Tofandel mentioned this issue Oct 17, 2019
34 tasks
@Tofandel
Copy link

Also it's possible to skip the change password step by setting the build flag WEB_FORCE_PASS_CHANGE to 0

@sfilinto
Copy link

i reset my devices sometimes so in order to bring them to a desired state very quickly i have made 2 .JSON files which have the desired configuration items. i run the below command to configure the device curl -F "[email protected]" -u admin:fibonacci http://192.168.4.1/config and it take a couple of seconds.
1st JSON file changes the default password & adds my wifi ssid & password.
login with a browser and reboot the device.
2nd JSON file has all the desired configuration and hostname.
again i login and reboot the device.

entire procedure take under 5 minutes to bring a device to a desired state & also avoids spelling mistakes.
HTH.

@Tofandel
Copy link

Tofandel commented Jan 27, 2020

@sfilinto if you want there is a trick to do that in one step even faster, use jq to merge your two json files, send the output via curl and tadam done should take less than 20 seconds
jq -s '.[0] * .[1]' 1.json 2.json | curl -H "Content-Type: application/json" -d @- -u admin:fibonacci http://192.168.4.1/config

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request web interface
Projects
None yet
Development

No branches or pull requests

4 participants