mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-10-01 20:36:51 +03:00
collapse the duplicated sentinel comment
This commit is contained in:
@@ -153,13 +153,9 @@ if [[ "$(id -u)" -eq 0 ]]; then
|
|||||||
if [[ "${FRIGATE_RUN_AS_ROOT:-false}" == "true" ]]; then
|
if [[ "${FRIGATE_RUN_AS_ROOT:-false}" == "true" ]]; then
|
||||||
rm -f /config/.permissions_version
|
rm -f /config/.permissions_version
|
||||||
else
|
else
|
||||||
# Only record the sentinel when something is mounted under /media: a
|
# Only bless the sentinel when a mount backs /media/frigate itself or
|
||||||
# sweep blessed against the container-local dir created below would let
|
# below it. A parent /media mount doesn't count: a dedicated
|
||||||
# a volume attached later skip the sweep forever
|
# /media/frigate volume added later would be shadowed and skipped.
|
||||||
# Only bless the sentinel when persistent storage actually backs
|
|
||||||
# /media/frigate, i.e. a mount at that exact path or below it. A mount
|
|
||||||
# at the /media parent does not count: a dedicated /media/frigate volume
|
|
||||||
# added later would shadow the swept directory and be skipped forever.
|
|
||||||
sentinel_args=(--sentinel /config/.permissions_version)
|
sentinel_args=(--sentinel /config/.permissions_version)
|
||||||
if ! awk '$2 == "/media/frigate" || $2 ~ /^\/media\/frigate\//' /proc/mounts | grep -q .; then
|
if ! awk '$2 == "/media/frigate" || $2 ~ /^\/media\/frigate\//' /proc/mounts | grep -q .; then
|
||||||
sentinel_args=()
|
sentinel_args=()
|
||||||
|
|||||||
Reference in New Issue
Block a user