fix(docker): remove Vite hot file at boot to prevent localhost:5173 asset URLs

This commit is contained in:
Thorsten Bus 2026-03-31 11:05:35 +02:00
parent d8da3ba678
commit 1fb07f40c9
2 changed files with 5 additions and 0 deletions

View file

@ -12,6 +12,7 @@
vendor/
node_modules/
public/hot
tests/
test-results/

View file

@ -24,6 +24,10 @@ mkdir -p \
chown -R www-data:www-data storage bootstrap/cache database 2>/dev/null || true
chmod -R 775 storage bootstrap/cache database 2>/dev/null || true
# Remove Vite dev server hot file if it leaked into the bind-mounted public/
# (causes Laravel to try localhost:5173 instead of reading the manifest)
rm -f /app/public/hot
# Sync built Vite assets from the image (public-build/) into the
# bind-mounted public/ directory. This ensures Caddy always serves
# up-to-date assets even though public/ is a host bind-mount.