server-side-backups-client issueshttps://gitlab.nic.cz/turris/server-side-backups-client/-/issues2020-01-01T22:22:40+01:00https://gitlab.nic.cz/turris/server-side-backups-client/-/issues/8Return apropriate error and exit code when backup file is too large2020-01-01T22:22:40+01:00Vojtech MyslivecReturn apropriate error and exit code when backup file is too largeThere is a backup size limit on the server side. When the backup is too large, `ssbackups` client exits with 255 error code and print json to `stdout`:
```
root@omnia: ~ # ssbackups create bigfile.bak
Password for backup:
Password for ...There is a backup size limit on the server side. When the backup is too large, `ssbackups` client exits with 255 error code and print json to `stdout`:
```
root@omnia: ~ # ssbackups create bigfile.bak
Password for backup:
Password for backup (again):
{"type": "ClientException", "detail": "Command << ['/usr/bin/curl', '--fail', '-X', 'POST', '-m', '10', '-H', 'Accept:application/json', '-H', 'Authorization:Token 01234DEADBEEF', '-F', 'payload=@bigfile.bak', 'https://rb.turris.cz/backups/'] >> ended with << return code = 22 >> and with output << >>.", "exit_code": -1}
```
Foris wrongly reports `"Failed to connect to the ssbackup server."` then (see screenshot).
- [x] `ssbackups` cli client should report some apropriate message on `stderr` and return defined exit code
- [x] Foris should report similar error message instead of general `"Failed to connect..."`
- [ ] A *notification message* should be raised when (regular timed) backup was not finished successfully, so the user get noticed that the backups are not created periodically
![screenshot](/uploads/15a42817e88309a8645677cefb0e8b91/Screenshot_from_2018-05-17_14-00-35.png)
cc: @mmladek @shenekŠtěpán HenekŠtěpán Henek