FEAT: Storage API & Frontend (#3409)

* Get storage output stats for each camera

* Add storage route

* Add storage route

* Add storage page

* Cleanup

* Add stats and show more storage

* Add tests for mb abbrev util fun

* Rewrite storage logic to use storage maintainer and segment sizes

* Include storage maintainer for http

* Use correct format

* Remove utils

* Fix tests

* Remove total from equation

* Multiply by 100 to get percent

* Add basic storage info

* Fix storage stats

* Fix endpoint and ui

* Fix formatting
This commit is contained in:
Nicolas Mowen
2022-11-29 18:59:56 -07:00
committed by GitHub
parent 25a7c4ee81
commit 5ad391977e
9 changed files with 172 additions and 10 deletions

View File

@@ -163,6 +163,7 @@ class FrigateApp:
self.db,
self.stats_tracking,
self.detected_frames_processor,
self.storage_maintainer,
self.plus_api,
)
@@ -362,13 +363,13 @@ class FrigateApp:
self.start_detected_frames_processor()
self.start_camera_processors()
self.start_camera_capture_processes()
self.start_storage_maintainer()
self.init_stats()
self.init_web_server()
self.start_event_processor()
self.start_event_cleanup()
self.start_recording_maintainer()
self.start_recording_cleanup()
self.start_storage_maintainer()
self.start_stats_emitter()
self.start_watchdog()
# self.zeroconf = broadcast_zeroconf(self.config.mqtt.client_id)