mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-05 10:45:21 +03:00
Enable auto vacuums
This commit is contained in:
parent
d3949eebfa
commit
5d8bcc0c38
@ -205,7 +205,10 @@ class FrigateApp:
|
||||
def bind_database(self) -> None:
|
||||
"""Bind db to the main process."""
|
||||
# NOTE: all db accessing processes need to be created before the db can be bound to the main process
|
||||
self.db = SqliteQueueDatabase(self.config.database.path)
|
||||
self.db = SqliteQueueDatabase(
|
||||
self.config.database.path,
|
||||
pragmas={'auto_vacuum', 'FULL'}, # Does not defragment database
|
||||
)
|
||||
models = [Event, Recordings, Timeline]
|
||||
self.db.bind(models)
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user