RS Backup: a backup/restore program for your console


Hi @all,

I pushed some code for a backup/restore command line util written in node.js last night:

It’s not published on NPM yet, because I wanted to wait for some positive testing feedback first. You can clone the repo and either use the scripts directly via node backup.js and node restore.js or you can install and link the executables globally via npm install -g . in the repo root. The latter gives you rs-backup and rs-restore commands.

There’s no discovery or auth yet, so you’ll have to provide the actual storage base URL (e.g. for 5apps that would be and a valid token for either the whole storage or the category you’re trying to backup/restore.

PRs are very welcome, of course. The whole thing is less than 200 lines of code and really simple. It’s more of a quick hack actually, but I could reliably migrate storage accounts with it so far.

Would be great if some of you could try it out and let me know if it worked for you. Thanks!


I was searching for something like this since more than 3 years :smiley:
Even built (and failed) my own version before:
The CLI approach is way simpler.
I will give it a try!


Hehe, nice name! :wink:

I made it a CLI, so it can also be set up as a cron job and such. Whoever wants to could also use Electron to give it some desktop UI. How about you deprecate yours and we collaborate on the new one then?

Edit: I would move it to the RS org, if someone is willing to help me maintain it properly.


Published on npm, so npm i -g rs-backup should work now.


Just published an update with discovery via user address.


… and now it also has interactive auth so you don’t need to acquire a token on your own, if you don’t want to.


I just published a new version of rs-backup, which fixes an issue with restoring large amounts of files.


Aand published another new version, including rate limiting for requests contributed by @galfert. Thanks!

It uses sensible defaults, so you don’t flood your server/provider with too many requests, but it’s also configurable via a new option flag (-r).


Version 1.6.0 of rs-backup has been released. Here's what's new:


  • Properly encode all URIs for backups (i.e. GET requests)
  • Log errors and do not write files for unsuccessful responses (anything other than 200/304)


  • Color error lines in red


Version 1.6.1 of rs-backup has been released. Here's what's new:


  • Fix last remaining encoding issues with # characters and some other special chars


Version 1.6.2 of rs-backup has been released. Here's what's new:


  • Don't encode slashes in pathnames, as it's not supported by all known RS servers


Version 1.7.0 of rs-backup has been released. Here's what's new:


  • Do not ask for user address in prompt, if already supplied via CLI argument
  • Tell user when permission is denied, and abort program
  • Improve output (colors, format)


Version 1.7.1 of rs-backup has been released. Here's what's new:


  • Show the actual reason/error when a Webfinger HTTP request fails
  • Don't fail and exit the program when a local file can't be read. Show an error instead.


  • Update webfinger.js