diff options
author | Javier Sánchez Parra <jsanchez@soleta.eu> | 2021-03-30 14:23:28 +0200 |
---|---|---|
committer | OpenGnSys Support Team <soporte-og@soleta.eu> | 2021-05-20 18:44:30 +0200 |
commit | 8441d844d104900f987f874dbddb46aa2503ddda (patch) | |
tree | 91dce13e312ec93e4a6c01eb9ce313eb813fdcf6 /ogcp/views.py | |
parent | 7f0d1ab287285e3903ff5507d68565aa393de3a0 (diff) |
Add disk stats to the dashboard
Add the following disk stats to the dashboard:
* Disk size: shows the amount of total disk size in Gibibytes.
* used: shows the amount of used disk size in Gibibytes.
* available: shows the amount of free disk size in Gibibytes.
* use(%): shows the amount of used disk size in percentage.
Diffstat (limited to 'ogcp/views.py')
-rw-r--r-- | ogcp/views.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ogcp/views.py b/ogcp/views.py index 09454f7..e9a40c8 100644 --- a/ogcp/views.py +++ b/ogcp/views.py @@ -124,8 +124,9 @@ def index(): images_response = g.server.get('/images') images = images_response.json()['images'] images.sort(key=image_modified_date_from_str, reverse=True) + disk = images_response.json()['disk'] return render_template('dashboard.html', clients=clients, - images=images) + images=images, disk=disk) return render_template('base.html') @app.route('/login', methods=['GET', 'POST']) |