composer install --optimize-autoloader --no-dev
npm install --production
npm run build
cp .env.example .env
php artisan key:generate
php artisan migrate --force
php artisan uploads:link
php artisan config:clear
php artisan route:clear
php artisan view:clear
php artisan cache:clear
Use the composer script for complete deployment:
composer run deploy
This will:
The uploads:link command creates a symbolic link from /opt/homebrew/var/www/staff/uploads to public/uploads, making uploaded files accessible via web.
php artisan uploads:link
php artisan uploads:link --force
/opt/homebrew/var/www/staff/uploads/
├── staff/
│ └── signature/ # Staff signature images
├── summernote/ # Rich text editor uploads
└── ... # Other uploaded documents
mklink /J (junction)symlink()chmod -R 755 storage/app/uploads
chown -R www-data:www-data storage/app/uploads
ls -la public/uploads
# Should show: lrwxr-xr-x ... public/uploads -> /path/to/storage/app/uploads