40 lines
985 B
YAML
40 lines
985 B
YAML
version: "3.9"
|
|
|
|
services:
|
|
frigate:
|
|
container_name: frigate
|
|
image: ghcr.io/blakeblackshear/frigate:stable-tensorrt
|
|
restart: unless-stopped
|
|
stop_grace_period: 30s
|
|
shm_size: "4gb"
|
|
gpus: all
|
|
security_opt:
|
|
- no-new-privileges:true
|
|
environment:
|
|
TZ: Europe/Zurich
|
|
NVIDIA_VISIBLE_DEVICES: all
|
|
NVIDIA_DRIVER_CAPABILITIES: compute,video,utility
|
|
LIBVA_DRIVER_NAME: nvidia
|
|
devices:
|
|
- /dev/bus/usb:/dev/bus/usb
|
|
- /dev/dri:/dev/dri
|
|
tmpfs:
|
|
- /tmp/cache:size=4G
|
|
volumes:
|
|
- /etc/localtime:/etc/localtime:ro
|
|
- /opt/frigate/config:/config
|
|
- /opt/frigate/media:/media/frigate
|
|
ports:
|
|
- "5000:5000"
|
|
- "1935:1935"
|
|
healthcheck:
|
|
test: ["CMD", "curl", "-f", "http://localhost:5000/api/version"]
|
|
interval: 30s
|
|
timeout: 10s
|
|
retries: 3
|
|
start_period: 60s
|
|
logging:
|
|
driver: json-file
|
|
options:
|
|
max-size: "100m"
|
|
max-file: "5" |