mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-10-26 08:24:42 +03:00
Compare commits
2
Commits
b1b725b80a
...
b02aea03cd
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b02aea03cd | ||
|
|
51171319a4 |
@@ -191,14 +191,12 @@ cameras:
|
||||
detect:
|
||||
enabled: false
|
||||
record:
|
||||
enabled: false
|
||||
enabled: true
|
||||
profiles:
|
||||
away:
|
||||
enabled: true
|
||||
detect:
|
||||
enabled: true
|
||||
record:
|
||||
enabled: true
|
||||
home:
|
||||
enabled: false
|
||||
```
|
||||
@@ -251,6 +249,12 @@ Leaving the `objects` section empty (or omitting `track`) does not clear the lis
|
||||
|
||||
Fields that require a Frigate restart to take effect cannot be overridden by profiles, since profiles are applied at runtime without restarting. Those fields are hidden when editing a profile override and can only be changed on the base configuration.
|
||||
|
||||
### Why can't a profile enable recording when it's disabled in the base config?
|
||||
|
||||
Frigate only sets up a camera's recording stream at startup when recording is enabled in the base config, so enabling it later from a profile has no effect. The same applies to turning recording on from the UI or MQTT.
|
||||
|
||||
To keep recording off by default, leave `record.enabled: true` in the base config and create a profile that sets `record.enabled: false`. Activate that profile and it will be restored automatically when Frigate starts.
|
||||
|
||||
### Can I schedule profiles to be enabled or disabled at certain times?
|
||||
|
||||
Not within Frigate itself. Frigate is an NVR, not an automation platform, so it intentionally does not include a scheduler for activating profiles. Instead, activate profiles from an automation platform that already handles time- and event-based triggers well, such as [Home Assistant](https://www.home-assistant.io/) or [Node-RED](https://nodered.org/). These integrate with Frigate and give you far more robust and flexible scheduling than a built-in scheduler could.
|
||||
|
||||
@@ -1952,7 +1952,11 @@
|
||||
"modelSizeLarge": "The 'large' model is optimized for multi-line license plates. The 'small' model provides better performance over 'large' and should be used unless your region uses multi-line plate formats."
|
||||
},
|
||||
"record": {
|
||||
"noRecordRole": "No streams have the record role defined. Recording will not function."
|
||||
"noRecordRole": "No streams have the record role defined. Recording will not function.",
|
||||
"profileBaseDisabled": "Recording is disabled in this camera's base config, so enabling it in a profile has no effect. Enable recording in the base config and use a profile to disable it instead."
|
||||
},
|
||||
"notifications": {
|
||||
"profileBaseDisabled": "No cameras have notifications enabled in their base config, so enabling them in a profile has no effect. Enable notifications in the base config of at least one camera."
|
||||
},
|
||||
"birdseye": {
|
||||
"objectsModeDetectDisabled": "Birdseye is set to 'objects' mode, but object detection is disabled for this camera. The camera will not appear in Birdseye."
|
||||
|
||||
@@ -8,6 +8,23 @@ const notifications: SectionConfigOverrides = {
|
||||
fieldGroups: {},
|
||||
hiddenFields: ["enabled_in_config"],
|
||||
advancedFields: [],
|
||||
fieldMessages: [
|
||||
{
|
||||
key: "profile-base-notifications-disabled",
|
||||
field: "enabled",
|
||||
messageKey: "configMessages.notifications.profileBaseDisabled",
|
||||
severity: "warning",
|
||||
position: "after",
|
||||
condition: (ctx) =>
|
||||
!!ctx.profileName &&
|
||||
ctx.formData?.enabled === true &&
|
||||
!Object.values(ctx.fullConfig.cameras).some(
|
||||
(camera) =>
|
||||
camera.enabled_in_config &&
|
||||
camera.notifications.enabled_in_config,
|
||||
),
|
||||
},
|
||||
],
|
||||
},
|
||||
global: {
|
||||
uiSchema: {
|
||||
|
||||
@@ -16,6 +16,21 @@ const record: SectionConfigOverrides = {
|
||||
},
|
||||
},
|
||||
],
|
||||
fieldMessages: [
|
||||
{
|
||||
key: "profile-base-record-disabled",
|
||||
field: "enabled",
|
||||
messageKey: "configMessages.record.profileBaseDisabled",
|
||||
severity: "warning",
|
||||
position: "after",
|
||||
docLink:
|
||||
"/configuration/profiles#why-cant-a-profile-enable-recording-when-its-disabled-in-the-base-config",
|
||||
condition: (ctx) =>
|
||||
!!ctx.profileName &&
|
||||
ctx.formData?.enabled === true &&
|
||||
ctx.fullCameraConfig?.record.enabled_in_config === false,
|
||||
},
|
||||
],
|
||||
fieldDocs: {
|
||||
"alerts.pre_capture":
|
||||
"/configuration/record#pre-capture-and-post-capture",
|
||||
|
||||
@@ -8,6 +8,7 @@ export type MessageConditionContext = {
|
||||
fullCameraConfig?: CameraConfig;
|
||||
level: "global" | "camera";
|
||||
cameraName?: string;
|
||||
profileName?: string;
|
||||
formData: ConfigSectionData;
|
||||
};
|
||||
|
||||
|
||||
@@ -619,9 +619,10 @@ export function ConfigSection({
|
||||
: undefined,
|
||||
level: effectiveLevel,
|
||||
cameraName,
|
||||
profileName,
|
||||
formData: currentFormData as ConfigSectionData,
|
||||
};
|
||||
}, [config, currentFormData, effectiveLevel, cameraName]);
|
||||
}, [config, currentFormData, effectiveLevel, cameraName, profileName]);
|
||||
|
||||
const { activeMessages, activeFieldMessages } = useConfigMessages(
|
||||
sectionConfig.messages,
|
||||
|
||||
Reference in New Issue
Block a user