From 53630be66829284a32c120d400d56ea2a4cddc9c Mon Sep 17 00:00:00 2001 From: Lachlan MacPhee Date: Sat, 11 May 2024 23:26:33 +1000 Subject: [PATCH 1/4] Minimal config in installation guide (#11339) + Adds a subsection to the installation guide that mentions the requirement for a minimal config to start Frigate successfully. + Adds a warning not to proceed any further into the guide without this valid config --- docs/docs/frigate/installation.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/docs/docs/frigate/installation.md b/docs/docs/frigate/installation.md index 59c196d0d8..3a7efa234d 100644 --- a/docs/docs/frigate/installation.md +++ b/docs/docs/frigate/installation.md @@ -53,6 +53,9 @@ Users of the Snapcraft build of Docker cannot use storage locations outside your ::: +### Creating a minimal configuration +For Frigate to start, you will need to have a valid configuration file inside your `config/` directory mentioned in the storage section of this page. You can find a minimal reference configuration with a dummy camera on the [full reference config page](https://docs.frigate.video/configuration/reference/). + ### Calculating required shm-size Frigate utilizes shared memory to store frames during processing. The default `shm-size` provided by Docker is **64MB**. @@ -78,6 +81,12 @@ $ python -c 'print("{:.2f}MB".format(((1280 * 720 * 1.5 * 9 + 270480) / 1048576) The shm size cannot be set per container for Home Assistant add-ons. However, this is probably not required since by default Home Assistant Supervisor allocates `/dev/shm` with half the size of your total memory. If your machine has 8GB of memory, chances are that Frigate will have access to up to 4GB without any additional configuration. +:::warning + +Before proceeding, make sure you have setup a valid, minimal configuration, or full configuration if you already know what you are doing! + +::: + ### Raspberry Pi 3/4 By default, the Raspberry Pi limits the amount of memory available to the GPU. In order to use ffmpeg hardware acceleration, you must increase the available memory by setting `gpu_mem` to the maximum recommended value in `config.txt` as described in the [official docs](https://www.raspberrypi.org/documentation/computers/config_txt.html#memory-options). From 5159b497e3225d221d792b8dbf1b6e5f15e6c92e Mon Sep 17 00:00:00 2001 From: Lachlan MacPhee Date: Sat, 11 May 2024 23:50:39 +1000 Subject: [PATCH 2/4] Add spacing between Markdown title and text Co-authored-by: Nicolas Mowen --- docs/docs/frigate/installation.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/docs/frigate/installation.md b/docs/docs/frigate/installation.md index 3a7efa234d..c9ebb93fd3 100644 --- a/docs/docs/frigate/installation.md +++ b/docs/docs/frigate/installation.md @@ -54,6 +54,7 @@ Users of the Snapcraft build of Docker cannot use storage locations outside your ::: ### Creating a minimal configuration + For Frigate to start, you will need to have a valid configuration file inside your `config/` directory mentioned in the storage section of this page. You can find a minimal reference configuration with a dummy camera on the [full reference config page](https://docs.frigate.video/configuration/reference/). ### Calculating required shm-size From a6b48112a7f1c5b41a54a032e4d8479e856d5e7e Mon Sep 17 00:00:00 2001 From: Lachlan MacPhee Date: Sat, 11 May 2024 23:58:27 +1000 Subject: [PATCH 3/4] Remove subsection in favour of exclusively adding a warning --- docs/docs/frigate/installation.md | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/docs/docs/frigate/installation.md b/docs/docs/frigate/installation.md index c9ebb93fd3..4277f6d8ca 100644 --- a/docs/docs/frigate/installation.md +++ b/docs/docs/frigate/installation.md @@ -28,6 +28,12 @@ Frigate uses the following locations for read/write operations in the container. - `/tmp/cache`: Cache location for recording segments. Initial recordings are written here before being checked and converted to mp4 and moved to the recordings folder. Segments generated via the `clip.mp4` endpoints are also concatenated and processed here. It is recommended to use a [`tmpfs`](https://docs.docker.com/storage/tmpfs/) mount for this. - `/dev/shm`: Internal cache for raw decoded frames in shared memory. It is not recommended to modify this directory or map it with docker. The minimum size is impacted by the `shm-size` calculations below. +:::warning + +For Frigate to start, you will need to have a valid configuration file inside your `config/` directory mentioned above. You can find a minimal reference configuration with a dummy camera on the [full reference config page](https://docs.frigate.video/configuration/reference/). + +::: + #### Common docker compose storage configurations Writing to a local disk or external USB drive: @@ -53,10 +59,6 @@ Users of the Snapcraft build of Docker cannot use storage locations outside your ::: -### Creating a minimal configuration - -For Frigate to start, you will need to have a valid configuration file inside your `config/` directory mentioned in the storage section of this page. You can find a minimal reference configuration with a dummy camera on the [full reference config page](https://docs.frigate.video/configuration/reference/). - ### Calculating required shm-size Frigate utilizes shared memory to store frames during processing. The default `shm-size` provided by Docker is **64MB**. @@ -82,12 +84,6 @@ $ python -c 'print("{:.2f}MB".format(((1280 * 720 * 1.5 * 9 + 270480) / 1048576) The shm size cannot be set per container for Home Assistant add-ons. However, this is probably not required since by default Home Assistant Supervisor allocates `/dev/shm` with half the size of your total memory. If your machine has 8GB of memory, chances are that Frigate will have access to up to 4GB without any additional configuration. -:::warning - -Before proceeding, make sure you have setup a valid, minimal configuration, or full configuration if you already know what you are doing! - -::: - ### Raspberry Pi 3/4 By default, the Raspberry Pi limits the amount of memory available to the GPU. In order to use ffmpeg hardware acceleration, you must increase the available memory by setting `gpu_mem` to the maximum recommended value in `config.txt` as described in the [official docs](https://www.raspberrypi.org/documentation/computers/config_txt.html#memory-options). From fcfe2e2c3cc755f5fdab63f1eb93cffcf8f71f03 Mon Sep 17 00:00:00 2001 From: Lachlan MacPhee Date: Sun, 12 May 2024 00:04:02 +1000 Subject: [PATCH 4/4] Adjust wording for the warning Co-authored-by: Nicolas Mowen --- docs/docs/frigate/installation.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/docs/frigate/installation.md b/docs/docs/frigate/installation.md index 4277f6d8ca..9399f775eb 100644 --- a/docs/docs/frigate/installation.md +++ b/docs/docs/frigate/installation.md @@ -30,7 +30,7 @@ Frigate uses the following locations for read/write operations in the container. :::warning -For Frigate to start, you will need to have a valid configuration file inside your `config/` directory mentioned above. You can find a minimal reference configuration with a dummy camera on the [full reference config page](https://docs.frigate.video/configuration/reference/). +For Frigate to start, it requires a valid configuration file inside the `/config/` directory mentioned above. There is a step by step guide to creating a minimal configuration in the [getting started guide](https://docs.frigate.video/guides/getting_started#configuring-frigate). :::