When run on empty directory FileNotFoundError is raised. Include it in the list
of expected errors.
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
Make it conditional such that when the disk space information is not available
due to errors, we don't display the warning.
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
Like most other pages in the interface, use 'Cancel' buttons instead of 'Abort'
buttons.
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
- Downloaded archives can't be fully extracted as tar.gz is incomplete at the
end and corrupt. This is due to complete gzip streaming implementation that is
does not flush the final bytes of gzip stream. Remove custom implementation
and get gzipped stream directly from borg.
- Fix mimetype for .tar.gz to application/gzip.
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
- Don't set bufsize to 1 while streaming backup download. This is only effective
with text streams with universal_newline flag set. An actual buffer size of 1
is very inefficient and plain wrong. Leave the python default of
io.DEFAULT_BUFFER_SIZE.
- Minor simplification to argument passing.
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
When visiting homepage as a non-admin user, don't throw an error into the
console about not being able to get root partition information. This is a
regression from refactoring during backups change.
Fixes: #1468.
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
- Update documentation pointing to Bootstrap Glyphicons.
- Consistently use trash-o. It is also more clear at the sizes we are using.
- Use hourglass-o instead of hourglass.
- Use diaspora icon instead of generic icon for diaspora app.
- In cards, don't set 3x size. It is not used. Instead we are setting our custom
size.
- Remove unused CSS rule for .sidebar .fa
- Align the FreedomBox logo to center with 'Home' text.
- Fix swapped icons for 'Client Apps' button.
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
When a user running tests is root and borg is not installed, several tests fail
due to missing borg. Skip these tests when borg is not installed.
Reviewed-by: Michael Pimmer <info@fonfon.at>
- adapt action and write tests for accessing a borg repo directly
via borg+ssh, without mounting it
- some docstring updates
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
- fixes issues as supposed by jvalleroy
- new repositories always get a UUID so they can immediately be fully
used (mounted, queried etc) also before saving them
- remove test connection page -- errors are shown on form submission
- improved error handling when creating remote repositories
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
- integrate remote repositories into backups index page
- remove, mount and unmount repositories via UI
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
- introduce env_vars in backups script and access_params for more
uniform handling of access parameters
- added tests for creating and deleting an archive
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>