juicyfx / vercel-examples

📦 Example projects using Vercel platform. Using Node.js, PHP and others.
https://f3l1x.io
MIT License
323 stars 150 forks source link

ERROR: DEPLOY TO LARAVEL #150

Open diepdo1810 opened 6 months ago

diepdo1810 commented 6 months ago

Bug report

ERR

Screenshot from 2024-05-03 17-46-14

File vercel.json

Screenshot from 2024-05-03 17-44-56

Description

PROJECT:

Please help me. Thanks everyone

janglapuk commented 4 months ago

Bump.

Have you set APP_DEBUG=false in vercel.json environment? Take a look php-laravel in this repo.

If you want to keep debugging enabled, make a custom env entry APP_LOG_FILE=/tmp/laravel.log in vercel.json and modify config/logging.php:

// ...
'single' => [
    'driver' => 'single',
    'path' => env('APP_LOG_FILE', '/tmp/laravel.log'),
    'level' => 'debug',
],
// ...

Haven't tried this before. Just posted on mobile.

janglapuk commented 4 months ago

Another problem is: remapping original bootstrap/cache directory into writable /tmp/bootstrap/cache.

Make sure that /tmp/bootstrap/cache exists before everything is run. It could be done in the entry point index.php to check and create the directories with mkdir() recursively if it does not exist.

Update: it could be done with Redis or Memcached to handle the caches.