Database and files system backup
https://docs.spatie.be/laravel-backup/v5/installation-and-setup
composer require spatie/laravel-backup
https://docs.spatie.be/laravel-backup/v5/installation-and-setup
composer require spatie/laravel-backup
php artisan vendor:publish --provider="Spatie\Backup\BackupServiceProvider"
In your config/database.php file, edit the mysql database config and add:
'dump' => [
'dump_binary_path' => 'C:/xampp/mysql/bin/', // only the path, so without `mysqldump` or `pg_dump`
'use_single_transaction',
'timeout' => 60 * 5, // 5 minute timeout
],
Create a folder in storage\app site-backup.
Open config/backup.php file,
'name' => 'site-backup',//env('APP_NAME', 'laravel-backup'),
php artisan backup:run
No comments:
Post a Comment