Run the frigate service as the frigate user

This commit is contained in:
Josh Hawkins
2026-08-23 17:59:19 -05:00
parent 2347f954bb
commit 74aa85c646
3 changed files with 7 additions and 3 deletions
@@ -30,4 +30,8 @@ cd /opt/frigate || echo "[ERROR] Failed to change working directory to /opt/frig
# Replace the bash process with the Frigate process, redirecting stderr to stdout
exec 2>&1
exec python3 -u -m frigate
if [[ "$(id -u)" -ne 0 || "${FRIGATE_RUN_AS_ROOT:-false}" == "true" ]]; then
exec python3 -u -m frigate
else
exec s6-setuidgid frigate python3 -u -m frigate
fi
@@ -22,7 +22,7 @@ set -o errexit -o nounset -o pipefail
# Permissions-layout epoch. Bump to force a one-time re-sweep on upgrade
# (e.g. when the privilege-drop release must capture files created as root
# since the previous sweep).
schema=1
schema=2
dry_run=0
sentinel=""