summaryrefslogtreecommitdiffstats
path: root/ogcp
diff options
context:
space:
mode:
authorAlejandro Sirgo Rica <asirgo@soleta.eu>2024-06-19 10:55:23 +0200
committerAlejandro Sirgo Rica <asirgo@soleta.eu>2024-06-19 10:55:23 +0200
commit2ae6f37e60955521eb8637127b37c76c19a7f607 (patch)
treebd1909b1a1c7f5cef38fb6239bff08976b45fa76 /ogcp
parent521b7c81aca650256c10c105b213e75f9060c6c6 (diff)
views: improve cache check messages in image/restore
Improve the wording of the error message reporting the clients without enough cache to hold the image to be restored.
Diffstat (limited to 'ogcp')
-rw-r--r--ogcp/views.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/ogcp/views.py b/ogcp/views.py
index ced0b0f..b2c1994 100644
--- a/ogcp/views.py
+++ b/ogcp/views.py
@@ -767,10 +767,10 @@ def image_fits_in_cache(server, ips, image_size):
free_cache = cache_size - used_cache
if free_cache < image_size:
missing_cache = image_size - free_cache
- err_report += f'{ip}: needs {(missing_cache / (1024 ** 3)):.3f} free GiB<br>'
+ err_report += f'{ip} requires {(missing_cache / (1024 ** 3)):.3f} free GiB<br>'
if err_report:
- flash(f'Client cache error:<br>{err_report}', category='error')
+ flash(f'No space left on cache:<br>{err_report}', category='error')
return False
return True