make motion the default retain mode

This commit is contained in:
Blake Blackshear 2022-02-05 09:28:21 -06:00
parent 663bf05fd7
commit 34fa53afcc
2 changed files with 2 additions and 4 deletions

View File

@ -273,7 +273,7 @@ record:
# here, the segments will already be gone by the time this mode is applied. # here, the segments will already be gone by the time this mode is applied.
# For example, if the camera retain mode is "motion", the segments without motion are # For example, if the camera retain mode is "motion", the segments without motion are
# never stored, so setting the mode to "all" here won't bring them back. # never stored, so setting the mode to "all" here won't bring them back.
mode: active_objects mode: motion
# Optional: Per object retention days # Optional: Per object retention days
objects: objects:
person: 15 person: 15

View File

@ -72,9 +72,7 @@ class RetainModeEnum(str, Enum):
class RetainConfig(FrigateBaseModel): class RetainConfig(FrigateBaseModel):
default: float = Field(default=10, title="Default retention period.") default: float = Field(default=10, title="Default retention period.")
mode: RetainModeEnum = Field( mode: RetainModeEnum = Field(default=RetainModeEnum.motion, title="Retain mode.")
default=RetainModeEnum.active_objects, title="Retain mode."
)
objects: Dict[str, float] = Field( objects: Dict[str, float] = Field(
default_factory=dict, title="Object retention period." default_factory=dict, title="Object retention period."
) )