Create /media/frigate after the ownership sweep

This commit is contained in:
Josh Hawkins
2026-08-27 07:47:58 -05:00
parent d109cc0ef8
commit 9deb34fa16
@@ -157,3 +157,13 @@ if [[ "$(id -u)" -eq 0 ]]; then
"${PUID:-1000}" "${PGID:-1000}" /config /media/frigate
fi
fi
# Not in the image, and the runtime user cannot create it under root-owned
# /media. Must stay after the sweep, which reads an absent /media/frigate as an
# unmounted volume rather than a swept one.
if [[ "$(id -u)" -eq 0 && ! -d /media/frigate ]]; then
mkdir -p /media/frigate
if [[ "${FRIGATE_RUN_AS_ROOT:-false}" != "true" ]]; then
chown "${PUID:-1000}:${PGID:-1000}" /media/frigate
fi
fi