Case: I uploaded a Laravel project on DigitalOcean using the following command in the Yaml file
run_command: |- php artisan migrate --force php artisan storage:link heroku-php-apache2 public/
Problem: Every time you deploy, these commands are run and the storage files are deleted. How to deploy without deleting uploaded files?
Additional Information:- 1-Table records are not deleted, only uploaded files are deleted 2- imagePath: base_url/storage/images/products/imageName.png
P粉5671123912024-03-30 16:28:33
Solution: This is not a problem. The problem is that every time you deploy, DigitalOcean is deployed on a different server (container) every time, so it's like a new device. But the table is not cleared, just the stored stuff