Frigate is an open-source Network Video Recorder (NVR) designed to run in a home lab with real-time AI-powered object detection. Frigate runs in Docker and integrates natively with Home Assistant.
System Requirements
- Linux OS (Ubuntu 20.04+ / Debian 11+ / Proxmox LXC)
- Minimum 4 GB RAM (8 GB+ recommended for multiple cameras)
- Sufficient storage for recordings (separate HDD/NVMe recommended)
- Docker & Docker Compose installed
- IP camera with RTSP stream
Install Docker & Docker Compose
If Docker is not installed yet, run the following commands (Ubuntu/Debian):
# Install dependencies apt update && apt install -y ca-certificates curl gnupg # Add Docker GPG key install -m 0755 -d /etc/apt/keyrings curl -fsSL https://download.docker.com/linux/ubuntu/gpg \ | gpg --dearmor -o /etc/apt/keyrings/docker.gpg # Add Docker repository echo \ "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] \ https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" \ | tee /etc/apt/sources.list.d/docker.list # Install Docker apt update && apt install -y docker-ce docker-ce-cli containerd.io docker-compose-plugin # Verify docker --version
Installation Steps
-
1
Create Directory Structure
mkdir -p /opt/frigate/config mkdir -p /opt/frigate/storage cd /opt/frigate
-
2
Create docker-compose.yml
Create the file
/opt/frigate/docker-compose.ymlwith the following content:services: frigate: container_name: frigate privileged: true restart: unless-stopped image: ghcr.io/blakeblackshear/frigate:stable shm_size: "128mb" devices: - /dev/bus/usb:/dev/bus/usb # Coral USB TPU (remove if not present) - /dev/dri/renderD128 # GPU acceleration (Intel/AMD) volumes: - /etc/localtime:/etc/localtime:ro - /opt/frigate/config:/config - /opt/frigate/storage:/media/frigate - type: tmpfs target: /tmp/cache tmpfs: size: 1000000000 ports: - "5000:5000" # Web UI - "8554:8554" # RTSP streams - "8555:8555/tcp" # WebRTC - "8555:8555/udp" environment: FRIGATE_RTSP_PASSWORD: "your_camera_password"Warning: Remove thedeviceslines that don't apply to your hardware. If you have no Coral TPU or GPU, remove the entiredevicesblock. -
3
Create the Frigate Configuration File
Create
/opt/frigate/config/config.yml. Below is a basic configuration example with one camera:mqtt: enabled: false # Enable if using Home Assistant detectors: cpu1: type: cpu num_threads: 3 cameras: front_camera: ffmpeg: inputs: - path: rtsp://user:password@192.168.1.101:554/stream1 roles: - detect - record detect: enabled: true width: 1280 height: 720 fps: 5 record: enabled: true retain: days: 7 mode: motion events: retain: default: 14 snapshots: enabled: true timestamp: true retain: default: 7 motion: mask: - 0,0,0,100,100,100,100,0 # Example masking area (optional) objects: track: - person - car - motorcycleRTSP URL tip: The RTSP URL format varies by camera. Tryrtsp://user:pass@IP:554/stream1or check your camera's manual. Tools like VLC can be used to test the stream before configuring it in Frigate. -
4
Start Frigate
cd /opt/frigate docker compose up -d # Monitor logs to check for errors docker compose logs -f frigate
Wait a few minutes for Frigate to finish initializing the detection model.
-
5
Access the Web UI
Open your browser and navigate to:
http://<Server-IP>:5000
From the Frigate dashboard you can view live streams from all cameras, detected events, and recordings.
Hardware Acceleration Configuration
Intel QSV / VAAPI (Intel iGPU)
Add to the ffmpeg section in the camera configuration:
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path: rtsp://...Make sure the /dev/dri/renderD128 device is mounted in docker-compose.
Google Coral USB TPU
Replace the detectors section in config.yml:
detectors:
coral:
type: edgetpu
device: usbUseful Commands
# Restart Frigate after editing config docker compose restart frigate # Update to the latest version docker compose pull docker compose up -d # Check resource usage docker stats frigate # Stop Frigate docker compose down
mqtt block in config.yml and install the Frigate integration in Home Assistant.