From cdb89d3287c7c9b6a68b7284a2b27ce3bbc710df Mon Sep 17 00:00:00 2001 From: Meghdad Date: Tue, 19 May 2026 19:44:01 +0330 Subject: [PATCH] fix running viewer-sync error on docker deploy --- dockerized/SKILL.md | 1 + dockerized/docker/app/entrypoint.sh | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/dockerized/SKILL.md b/dockerized/SKILL.md index 9384828..21f77d7 100644 --- a/dockerized/SKILL.md +++ b/dockerized/SKILL.md @@ -40,6 +40,7 @@ Only publish HTTP and RTMP by default. Keep MediaMTX HLS behind Apache and keep - When changing MediaMTX ports, update Compose environment, published ports, entrypoint defaults, and the template together. - When changing Laravel runtime behavior, update the shared `x-app-environment` block unless the value belongs to one role only. - When changing queue behavior, prefer env-driven options on the `queue` service and `docker/app/entrypoint.sh`. +- Do not run the long-lived Docker `viewer-sync` service with `--isolated`; a stale cache lock can make the command exit cleanly and trigger an endless container restart loop. - Keep `npm run build` after PHP setup and Composer install in `docker/app/Dockerfile`; the Wayfinder Vite plugin invokes `php artisan wayfinder:generate` during the build. The asset stage must also provide safe build-time Laravel env values, create Laravel writable directories such as `storage/framework/views`, and run `php artisan wayfinder:generate --with-form --no-interaction` before `npm run build` so failures are visible in Docker logs. - Do not call `php artisan storage:link --force` as `www-data` during container startup; `public/storage` lives in the root-owned image filesystem. Create the symlink as root in the entrypoint if it is missing. - Keep deploy script behavior idempotent: repeat runs should update the Git checkout, rebuild, migrate, and restart services without deleting volumes. diff --git a/dockerized/docker/app/entrypoint.sh b/dockerized/docker/app/entrypoint.sh index 686da03..0d9a480 100644 --- a/dockerized/docker/app/entrypoint.sh +++ b/dockerized/docker/app/entrypoint.sh @@ -131,7 +131,6 @@ case "$role" in ;; viewer-sync) exec gosu www-data php artisan streaming:sync-viewer-counts \ - --isolated \ --interval="${STREAMING_VIEWER_SYNC_INTERVAL:-2}" ;; artisan)